opts.go
func Resource(typ ResType, labels map[string]string) Option {
	return func(sh *StackdriverHook) error {
		return MonitoredResource(&logging.MonitoredResource{
			Type:   string(typ),
			Labels: labels,
		})(sh)
	}
}
func Resource(typ ResType, labels map[string]string) Option {
	return func(sh *StackdriverHook) error {
		return MonitoredResource(&logging.MonitoredResource{
			Type:   string(typ),
			Labels: labels,
		})(sh)
	}
}
// Resource is an option that sets the resource information to send with each
// log entry.
//
// Please see https://cloud.google.com/logging/docs/api/v2/resource-list for
// the list of labels required per ResType.