From cd87bbbdeaf87d757fdc6769c54776eafda531db Mon Sep 17 00:00:00 2001 From: Will Browne Date: Mon, 21 Jul 2025 13:55:30 +0100 Subject: [PATCH] Plugins: Remove externalCorePlugins feature toggle (#108386) remove externalCorePlugins feature toggle --- docs/sources/datasources/testdata/_index.md | 4 ---- docs/sources/setup-grafana/configure-grafana/_index.md | 2 -- .../configure-grafana/feature-toggles/index.md | 1 - packages/grafana-data/src/types/featureToggles.gen.ts | 5 ----- pkg/plugins/config/config.go | 1 - pkg/services/featuremgmt/registry.go | 7 ------- pkg/services/featuremgmt/toggles_gen.csv | 1 - pkg/services/featuremgmt/toggles_gen.go | 4 ---- pkg/services/featuremgmt/toggles_gen.json | 3 ++- pkg/services/pluginsintegration/pipeline/steps.go | 4 ---- pkg/services/pluginsintegration/pipeline/steps_test.go | 3 --- pkg/services/pluginsintegration/pluginconfig/config.go | 1 - 12 files changed, 2 insertions(+), 34 deletions(-) diff --git a/docs/sources/datasources/testdata/_index.md b/docs/sources/datasources/testdata/_index.md index fb03cebd5f5..e909f4d43f2 100644 --- a/docs/sources/datasources/testdata/_index.md +++ b/docs/sources/datasources/testdata/_index.md @@ -126,13 +126,9 @@ This feature is experimental and requires Grafana version 10.3.0 or later. If you want to use a version of TestData different from the one shipped with Grafana, follow these steps: -1. Enable the [feature toggle](https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/feature-toggles/) `externalCorePlugins`. 1. Set the configuration field `as_external` for the plugin to `true`. An example configuration would be: ```ini - [feature_toggles] - externalCorePlugins = true - [plugin.grafana-testdata-datasource] as_external = true ``` diff --git a/docs/sources/setup-grafana/configure-grafana/_index.md b/docs/sources/setup-grafana/configure-grafana/_index.md index 1ce20139b48..a79ccc33e70 100644 --- a/docs/sources/setup-grafana/configure-grafana/_index.md +++ b/docs/sources/setup-grafana/configure-grafana/_index.md @@ -2655,8 +2655,6 @@ If `true`, propagate the tracing context to the plugin backend and enable tracin Load an external version of a core plugin if it has been installed. -Experimental. Requires the feature toggle `externalCorePlugins` to be enabled. -
### `[plugin.grafana-image-renderer]` 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 a471a92f08c..5f3c0f3135e 100644 --- a/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md +++ b/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md @@ -42,7 +42,6 @@ Most [generally available](https://grafana.com/docs/release-life-cycle/#general- | `transformationsRedesign` | Enables the transformations redesign | Yes | | `awsAsyncQueryCaching` | Enable caching for async queries for Redshift and Athena. Requires that the datasource has caching and async query support enabled | Yes | | `dashgpt` | Enable AI powered features in dashboards | Yes | -| `externalCorePlugins` | Allow core plugins to be loaded as external | Yes | | `panelMonitoring` | Enables panel monitoring through logs and measurements | Yes | | `formatString` | Enable format string transformer | Yes | | `kubernetesClientDashboardsFolders` | Route the folder and dashboard service requests to k8s | Yes | diff --git a/packages/grafana-data/src/types/featureToggles.gen.ts b/packages/grafana-data/src/types/featureToggles.gen.ts index b6e1c38b994..743e9da474e 100644 --- a/packages/grafana-data/src/types/featureToggles.gen.ts +++ b/packages/grafana-data/src/types/featureToggles.gen.ts @@ -257,11 +257,6 @@ export interface FeatureToggles { */ lokiRunQueriesInParallel?: boolean; /** - * Allow core plugins to be loaded as external - * @default true - */ - externalCorePlugins?: boolean; - /** * Automatic service account and token setup for plugins */ externalServiceAccounts?: boolean; diff --git a/pkg/plugins/config/config.go b/pkg/plugins/config/config.go index 0a2fdce14f8..769c117219e 100644 --- a/pkg/plugins/config/config.go +++ b/pkg/plugins/config/config.go @@ -30,7 +30,6 @@ type PluginManagementCfg struct { // Features contains the feature toggles used for the plugin management system. type Features struct { - ExternalCorePluginsEnabled bool SkipHostEnvVarsEnabled bool SriChecksEnabled bool PluginsCDNSyncLoaderEnabled bool diff --git a/pkg/services/featuremgmt/registry.go b/pkg/services/featuremgmt/registry.go index 4b917d925e0..a34c8d9b940 100644 --- a/pkg/services/featuremgmt/registry.go +++ b/pkg/services/featuremgmt/registry.go @@ -420,13 +420,6 @@ var ( FrontendOnly: false, Owner: grafanaObservabilityLogsSquad, }, - { - Name: "externalCorePlugins", - Description: "Allow core plugins to be loaded as external", - Stage: FeatureStageGeneralAvailability, - Owner: grafanaPluginsPlatformSquad, - Expression: "true", // enabled by default - }, { Name: "externalServiceAccounts", Description: "Automatic service account and token setup for plugins", diff --git a/pkg/services/featuremgmt/toggles_gen.csv b/pkg/services/featuremgmt/toggles_gen.csv index c55c4438d1b..2abb60b551b 100644 --- a/pkg/services/featuremgmt/toggles_gen.csv +++ b/pkg/services/featuremgmt/toggles_gen.csv @@ -54,7 +54,6 @@ aiGeneratedDashboardChanges,experimental,@grafana/dashboards-squad,false,false,t reportingRetries,preview,@grafana/grafana-operator-experience-squad,false,true,false sseGroupByDatasource,experimental,@grafana/observability-metrics,false,false,false lokiRunQueriesInParallel,privatePreview,@grafana/observability-logs,false,false,false -externalCorePlugins,GA,@grafana/plugins-platform-backend,false,false,false externalServiceAccounts,preview,@grafana/identity-access-team,false,false,false panelMonitoring,GA,@grafana/dataviz-squad,false,false,true enableNativeHTTPHistogram,experimental,@grafana/grafana-backend-services-squad,false,true,false diff --git a/pkg/services/featuremgmt/toggles_gen.go b/pkg/services/featuremgmt/toggles_gen.go index b8c9548f0a0..19443a615f2 100644 --- a/pkg/services/featuremgmt/toggles_gen.go +++ b/pkg/services/featuremgmt/toggles_gen.go @@ -227,10 +227,6 @@ const ( // Enables running Loki queries in parallel FlagLokiRunQueriesInParallel = "lokiRunQueriesInParallel" - // FlagExternalCorePlugins - // Allow core plugins to be loaded as external - FlagExternalCorePlugins = "externalCorePlugins" - // FlagExternalServiceAccounts // Automatic service account and token setup for plugins FlagExternalServiceAccounts = "externalServiceAccounts" diff --git a/pkg/services/featuremgmt/toggles_gen.json b/pkg/services/featuremgmt/toggles_gen.json index 026968d3996..2d7f6f7b589 100644 --- a/pkg/services/featuremgmt/toggles_gen.json +++ b/pkg/services/featuremgmt/toggles_gen.json @@ -1250,7 +1250,8 @@ "metadata": { "name": "externalCorePlugins", "resourceVersion": "1750434297879", - "creationTimestamp": "2023-09-22T08:50:13Z" + "creationTimestamp": "2023-09-22T08:50:13Z", + "deletionTimestamp": "2025-07-21T09:49:02Z" }, "spec": { "description": "Allow core plugins to be loaded as external", diff --git a/pkg/services/pluginsintegration/pipeline/steps.go b/pkg/services/pluginsintegration/pipeline/steps.go index 3e33fda53be..8ac3b8a5aa2 100644 --- a/pkg/services/pluginsintegration/pipeline/steps.go +++ b/pkg/services/pluginsintegration/pipeline/steps.go @@ -223,10 +223,6 @@ func NewAsExternalStep(cfg *config.PluginManagementCfg) *AsExternal { // Filter will filter out any plugins that are marked to be disabled. func (c *AsExternal) Filter(cl plugins.Class, bundles []*plugins.FoundBundle) ([]*plugins.FoundBundle, error) { - if !c.cfg.Features.ExternalCorePluginsEnabled { - return bundles, nil - } - if cl == plugins.ClassCore { res := []*plugins.FoundBundle{} for _, bundle := range bundles { diff --git a/pkg/services/pluginsintegration/pipeline/steps_test.go b/pkg/services/pluginsintegration/pipeline/steps_test.go index 24b7def7bde..009d489d2ba 100644 --- a/pkg/services/pluginsintegration/pipeline/steps_test.go +++ b/pkg/services/pluginsintegration/pipeline/steps_test.go @@ -68,9 +68,6 @@ func TestAsExternal(t *testing.T) { t.Run("should skip a core plugin", func(t *testing.T) { cfg := &config.PluginManagementCfg{ - Features: config.Features{ - ExternalCorePluginsEnabled: true, - }, PluginSettings: setting.PluginSettings{ "plugin1": map[string]string{ "as_external": "true", diff --git a/pkg/services/pluginsintegration/pluginconfig/config.go b/pkg/services/pluginsintegration/pluginconfig/config.go index 86408ae0e6f..58b4d1dee06 100644 --- a/pkg/services/pluginsintegration/pluginconfig/config.go +++ b/pkg/services/pluginsintegration/pluginconfig/config.go @@ -30,7 +30,6 @@ func ProvidePluginManagementConfig(cfg *setting.Cfg, settingProvider setting.Pro cfg.PluginsCDNURLTemplate, cfg.AppURL, config.Features{ - ExternalCorePluginsEnabled: features.IsEnabledGlobally(featuremgmt.FlagExternalCorePlugins), SkipHostEnvVarsEnabled: features.IsEnabledGlobally(featuremgmt.FlagPluginsSkipHostEnvVars), SriChecksEnabled: features.IsEnabledGlobally(featuremgmt.FlagPluginsSriChecks), PluginsCDNSyncLoaderEnabled: features.IsEnabledGlobally(featuremgmt.FlagPluginsCDNSyncLoader),