Add prefix to datadog metrics

This commit is contained in:
Huan Wang 2021-10-06 09:34:07 -06:00 committed by GitHub
parent 32340252b2
commit 85dd45cb81
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 90 additions and 34 deletions

View file

@ -46,7 +46,7 @@ const (
func RegisterStatsd(ctx context.Context, config *types.Statsd) Registry {
// just to be sure there is a prefix defined
if config.Prefix == "" {
config.Prefix = "traefik"
config.Prefix = defaultMetricsPrefix
}
statsdClient = statsd.New(config.Prefix+".", kitlog.LoggerFunc(func(keyvals ...interface{}) error {