From 03c894489c8d6b498f4d87bed97305311c3190fc Mon Sep 17 00:00:00 2001 From: Timur Olzhabayev Date: Tue, 1 Apr 2025 14:59:32 +0200 Subject: [PATCH] Chore: Enabling failWrongDSUID by default in Grafana 12 (#102192) * enabling failWrongDSUID by default in Grafana 12 * making reviewdog happy * generating feature toggle files --- .../configure-grafana/feature-toggles/index.md | 2 +- .../grafana-data/src/types/featureToggles.gen.ts | 3 ++- pkg/services/featuremgmt/registry.go | 5 +++-- pkg/services/featuremgmt/toggles_gen.csv | 2 +- pkg/services/featuremgmt/toggles_gen.go | 2 +- pkg/services/featuremgmt/toggles_gen.json | 14 +++++++++----- 6 files changed, 17 insertions(+), 11 deletions(-) diff --git a/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md b/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md index e9476b99cca..f31373a2fcf 100644 --- a/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md +++ b/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md @@ -69,6 +69,7 @@ Most [generally available](https://grafana.com/docs/release-life-cycle/#general- | `pluginProxyPreserveTrailingSlash` | Preserve plugin proxy trailing slash. | | | `azureMonitorPrometheusExemplars` | Allows configuration of Azure Monitor as a data source that can provide Prometheus exemplars | Yes | | `pinNavItems` | Enables pinning of nav items | Yes | +| `failWrongDSUID` | Throws an error if a data source has an invalid UIDs | Yes | | `alertingApiServer` | Register Alerting APIs with the K8s API server | Yes | | `cloudWatchRoundUpEndTime` | Round up end time for metric queries to the next minute to avoid missing data | Yes | | `newFiltersUI` | Enables new combobox style UI for the Ad hoc filters variable in scenes architecture | Yes | @@ -192,7 +193,6 @@ Experimental features might be changed or removed without prior notice. | `alertingListViewV2` | Enables the new alert list view design | | `dashboardRestore` | Enables deleted dashboard restore feature | | `alertingCentralAlertHistory` | Enables the new central alert history. | -| `failWrongDSUID` | Throws an error if a datasource has an invalid UIDs | | `dataplaneAggregator` | Enable grafana dataplane aggregator | | `tableNextGen` | Allows access to the new react-data-grid based table component. | | `lokiSendDashboardPanelNames` | Send dashboard and panel names to Loki when querying | diff --git a/packages/grafana-data/src/types/featureToggles.gen.ts b/packages/grafana-data/src/types/featureToggles.gen.ts index 83a4d159d5e..f223d4d73b9 100644 --- a/packages/grafana-data/src/types/featureToggles.gen.ts +++ b/packages/grafana-data/src/types/featureToggles.gen.ts @@ -703,7 +703,8 @@ export interface FeatureToggles { */ ssoSettingsLDAP?: boolean; /** - * Throws an error if a datasource has an invalid UIDs + * Throws an error if a data source has an invalid UIDs + * @default true */ failWrongDSUID?: boolean; /** diff --git a/pkg/services/featuremgmt/registry.go b/pkg/services/featuremgmt/registry.go index b4a9fc335b4..fa350ab091c 100644 --- a/pkg/services/featuremgmt/registry.go +++ b/pkg/services/featuremgmt/registry.go @@ -1208,9 +1208,10 @@ var ( }, { Name: "failWrongDSUID", - Description: "Throws an error if a datasource has an invalid UIDs", - Stage: FeatureStageExperimental, + Description: "Throws an error if a data source has an invalid UIDs", + Stage: FeatureStageGeneralAvailability, Owner: grafanaPluginsPlatformSquad, + Expression: "true", // enabled by default }, { Name: "zanzana", diff --git a/pkg/services/featuremgmt/toggles_gen.csv b/pkg/services/featuremgmt/toggles_gen.csv index a940691dd62..ed7d50d0ae9 100644 --- a/pkg/services/featuremgmt/toggles_gen.csv +++ b/pkg/services/featuremgmt/toggles_gen.csv @@ -157,7 +157,7 @@ azureMonitorPrometheusExemplars,GA,@grafana/partner-datasources,false,false,fals pinNavItems,GA,@grafana/grafana-frontend-platform,false,false,false authZGRPCServer,experimental,@grafana/identity-access-team,false,false,false ssoSettingsLDAP,preview,@grafana/identity-access-team,false,true,false -failWrongDSUID,experimental,@grafana/plugins-platform-backend,false,false,false +failWrongDSUID,GA,@grafana/plugins-platform-backend,false,false,false zanzana,experimental,@grafana/identity-access-team,false,false,false reloadDashboardsOnParamsChange,experimental,@grafana/dashboards-squad,false,false,false enableScopesInMetricsExplore,experimental,@grafana/dashboards-squad,false,false,false diff --git a/pkg/services/featuremgmt/toggles_gen.go b/pkg/services/featuremgmt/toggles_gen.go index 11f7841caf2..6212edd254a 100644 --- a/pkg/services/featuremgmt/toggles_gen.go +++ b/pkg/services/featuremgmt/toggles_gen.go @@ -640,7 +640,7 @@ const ( FlagSsoSettingsLDAP = "ssoSettingsLDAP" // FlagFailWrongDSUID - // Throws an error if a datasource has an invalid UIDs + // Throws an error if a data source has an invalid UIDs FlagFailWrongDSUID = "failWrongDSUID" // FlagZanzana diff --git a/pkg/services/featuremgmt/toggles_gen.json b/pkg/services/featuremgmt/toggles_gen.json index 732704a1628..0c86f44f391 100644 --- a/pkg/services/featuremgmt/toggles_gen.json +++ b/pkg/services/featuremgmt/toggles_gen.json @@ -1793,13 +1793,17 @@ { "metadata": { "name": "failWrongDSUID", - "resourceVersion": "1718721033692", - "creationTimestamp": "2024-06-20T10:56:39Z" + "resourceVersion": "1741956585324", + "creationTimestamp": "2024-06-20T10:56:39Z", + "annotations": { + "grafana.app/updatedTimestamp": "2025-03-14 12:49:45.324676 +0000 UTC" + } }, "spec": { - "description": "Throws an error if a datasource has an invalid UIDs", - "stage": "experimental", - "codeowner": "@grafana/plugins-platform-backend" + "description": "Throws an error if a data source has an invalid UIDs", + "stage": "GA", + "codeowner": "@grafana/plugins-platform-backend", + "expression": "true" } }, {