Prometheus: Enable the promQLScope (Scopes, Adhoc filters and groupby) by default (#92080)

This commit is contained in:
Kyle Brandt 2024-09-03 09:56:25 -04:00 committed by GitHub
parent 88259da745
commit d382ea773a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 17 additions and 10 deletions

View File

@ -62,6 +62,7 @@ Most [generally available](https://grafana.com/docs/release-life-cycle/#general-
| `logRowsPopoverMenu` | Enable filtering menu displayed when text of a log line is selected | Yes |
| `lokiQueryHints` | Enables query hints for Loki | Yes |
| `alertingQueryOptimization` | Optimizes eligible queries in order to reduce load on datasources | |
| `promQLScope` | In-development feature that will allow injection of labels into prometheus queries. | Yes |
| `groupToNestedTableTransformation` | Enables the group to nested table transformation | Yes |
| `tlsMemcached` | Use TLS-enabled memcached in the enterprise caching feature | Yes |
| `cloudWatchNewLabelParsing` | Updates CloudWatch label parsing to be more accurate | Yes |
@ -172,7 +173,6 @@ Experimental features might be changed or removed without prior notice.
| `tableSharedCrosshair` | Enables shared crosshair in table panel |
| `kubernetesFeatureToggles` | Use the kubernetes API for feature toggle management in the frontend |
| `newFolderPicker` | Enables the nested folder picker without having nested folders enabled |
| `promQLScope` | In-development feature that will allow injection of labels into prometheus queries. |
| `sqlExpressions` | Enables using SQL and DuckDB functions as Expressions. |
| `nodeGraphDotLayout` | Changed the layout algorithm for the node graph |
| `kubernetesAggregator` | Enable grafana's embedded kube-aggregator |

View File

@ -238,9 +238,11 @@ func Parse(span trace.Span, query backend.DataQuery, dsScrapeInterval string, in
}()))
}
expr, err = ApplyFiltersAndGroupBy(expr, scopeFilters, model.AdhocFilters, model.GroupByKeys)
if err != nil {
return nil, err
if len(scopeFilters) > 0 || len(model.AdhocFilters) > 0 || len(model.GroupByKeys) > 0 {
expr, err = ApplyFiltersAndGroupBy(expr, scopeFilters, model.AdhocFilters, model.GroupByKeys)
if err != nil {
return nil, err
}
}
}

View File

@ -1039,8 +1039,9 @@ var (
{
Name: "promQLScope",
Description: "In-development feature that will allow injection of labels into prometheus queries.",
Stage: FeatureStageExperimental,
Stage: FeatureStageGeneralAvailability,
Owner: grafanaObservabilityMetricsSquad,
Expression: "true",
},
{
Name: "sqlExpressions",

View File

@ -136,7 +136,7 @@ newFolderPicker,experimental,@grafana/grafana-frontend-platform,false,false,true
jitterAlertRulesWithinGroups,preview,@grafana/alerting-squad,false,true,false
onPremToCloudMigrations,preview,@grafana/grafana-operator-experience-squad,false,false,false
alertingSaveStatePeriodic,privatePreview,@grafana/alerting-squad,false,false,false
promQLScope,experimental,@grafana/observability-metrics,false,false,false
promQLScope,GA,@grafana/observability-metrics,false,false,false
sqlExpressions,experimental,@grafana/grafana-app-platform-squad,false,false,false
nodeGraphDotLayout,experimental,@grafana/observability-traces-and-profiling,false,false,true
groupToNestedTableTransformation,GA,@grafana/dataviz-squad,false,false,true

1 Name Stage Owner requiresDevMode RequiresRestart FrontendOnly
136 jitterAlertRulesWithinGroups preview @grafana/alerting-squad false true false
137 onPremToCloudMigrations preview @grafana/grafana-operator-experience-squad false false false
138 alertingSaveStatePeriodic privatePreview @grafana/alerting-squad false false false
139 promQLScope experimental GA @grafana/observability-metrics false false false
140 sqlExpressions experimental @grafana/grafana-app-platform-squad false false false
141 nodeGraphDotLayout experimental @grafana/observability-traces-and-profiling false false true
142 groupToNestedTableTransformation GA @grafana/dataviz-squad false false true

View File

@ -2188,13 +2188,17 @@
{
"metadata": {
"name": "promQLScope",
"resourceVersion": "1718727528075",
"creationTimestamp": "2024-01-29T20:22:17Z"
"resourceVersion": "1724076197892",
"creationTimestamp": "2024-01-29T20:22:17Z",
"annotations": {
"grafana.app/updatedTimestamp": "2024-08-19 14:03:17.892558375 +0000 UTC"
}
},
"spec": {
"description": "In-development feature that will allow injection of labels into prometheus queries.",
"stage": "experimental",
"codeowner": "@grafana/observability-metrics"
"stage": "GA",
"codeowner": "@grafana/observability-metrics",
"expression": "true"
}
},
{