Skip to content

Commit

Permalink
chore: don't disable pkg.translator.prometheus.NormalizeName by default
Browse files Browse the repository at this point in the history
This is now disabled by default in upstream as well.
  • Loading branch information
Mikołaj Świątek committed Jun 26, 2023
1 parent 4f57d7f commit 3716086
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions otelcolbuilder/cmd/configprovider.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,19 +36,12 @@ import (
// https://github.com/open-telemetry/opentelemetry-collector/blob/65dfc325d974be8ebb7c170b90c6646f9eaef27b/service/command.go#L38

func UseCustomConfigProvider(params *otelcol.CollectorSettings) error {
var err error
// feature flags, which are enabled by default in our distro
err = featuregate.GlobalRegistry().Set("extension.sumologic.updateCollectorMetadata", true)
if err != nil {
return fmt.Errorf("setting feature gate flags failed: %s", err)
}
err := featuregate.GlobalRegistry().Set("extension.sumologic.updateCollectorMetadata", true)

// see: https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/21743
err = featuregate.GlobalRegistry().Set("pkg.translator.prometheus.NormalizeName", false)
if err != nil {
return fmt.Errorf("setting feature gate flags failed: %s", err)
}

// to create the provider, we need config locations passed in via the command line
// to get these, we take the command the service uses to start, parse the flags, and read the values
flagset := flags(featuregate.GlobalRegistry())
Expand Down

0 comments on commit 3716086

Please sign in to comment.