diff --git a/static/metrics/instance/global.go b/static/metrics/instance/global.go index 38643b7a94f9..24036b55d3d4 100644 --- a/static/metrics/instance/global.go +++ b/static/metrics/instance/global.go @@ -17,6 +17,8 @@ type GlobalConfig struct { Prometheus config.GlobalConfig `yaml:",inline"` RemoteWrite []*config.RemoteWriteConfig `yaml:"remote_write,omitempty"` + EnableProtobufNegotiation bool `yaml:"enable_protobuf_negotiation,omitempty"` + ExtraMetrics bool `yaml:"-"` DisableKeepAlives bool `yaml:"-"` IdleConnTimeout time.Duration `yaml:"-"` diff --git a/static/metrics/instance/instance.go b/static/metrics/instance/instance.go index 1e264ca76b8c..592b073cc364 100644 --- a/static/metrics/instance/instance.go +++ b/static/metrics/instance/instance.go @@ -439,8 +439,9 @@ func (i *Instance) initialize(ctx context.Context, reg prometheus.Registerer, cf i.storage = storage.NewFanout(i.logger, i.wal, i.remoteStore) opts := &scrape.Options{ - ExtraMetrics: cfg.global.ExtraMetrics, - HTTPClientOptions: []config_util.HTTPClientOption{}, + ExtraMetrics: cfg.global.ExtraMetrics, + HTTPClientOptions: []config_util.HTTPClientOption{}, + EnableProtobufNegotiation: cfg.global.EnableProtobufNegotiation, } if cfg.global.DisableKeepAlives {