diff --git a/operators/multiclusterobservability/controllers/multiclusterobservability/grafana.go b/operators/multiclusterobservability/controllers/multiclusterobservability/grafana.go index a88d5720a..832f316ad 100644 --- a/operators/multiclusterobservability/controllers/multiclusterobservability/grafana.go +++ b/operators/multiclusterobservability/controllers/multiclusterobservability/grafana.go @@ -54,11 +54,12 @@ type GrafanaDatasource struct { } type JsonData struct { - TLSAuth bool `yaml:"tlsAuth,omitempty"` - TLSAuthCA bool `yaml:"tlsAuthWithCACert,omitempty"` - QueryTimeout string `yaml:"queryTimeout,omitempty"` - HttpMethod string `yaml:"httpMethod,omitempty"` - TimeInterval string `yaml:"timeInterval,omitempty"` + TLSAuth bool `yaml:"tlsAuth,omitempty"` + TLSAuthCA bool `yaml:"tlsAuthWithCACert,omitempty"` + QueryTimeout string `yaml:"queryTimeout,omitempty"` + HttpMethod string `yaml:"httpMethod,omitempty"` + TimeInterval string `yaml:"timeInterval,omitempty"` + CustomQueryParameters string `yaml:"customQueryParameters,omitempty"` } type SecureJsonData struct { @@ -94,8 +95,9 @@ func GenerateGrafanaDataSource( config.GetDefaultNamespace(), ), JSONData: &JsonData{ - QueryTimeout: "300s", - TimeInterval: fmt.Sprintf("%ds", mco.Spec.ObservabilityAddonSpec.Interval), + QueryTimeout: "300s", + CustomQueryParameters: "max_source_resolution=auto", + TimeInterval: fmt.Sprintf("%ds", mco.Spec.ObservabilityAddonSpec.Interval), }, }, { @@ -109,8 +111,9 @@ func GenerateGrafanaDataSource( config.GetDefaultNamespace(), ), JSONData: &JsonData{ - QueryTimeout: "300s", - TimeInterval: fmt.Sprintf("%ds", DynamicTimeInterval), + QueryTimeout: "300s", + CustomQueryParameters: "max_source_resolution=auto", + TimeInterval: fmt.Sprintf("%ds", DynamicTimeInterval), }, }, },