datasources: querier: do not check for related toggles (#111586)

datasources: querier: do not check for realted toggles
This commit is contained in:
Gábor Farkas
2025-09-25 14:09:13 +02:00
committed by GitHub
parent 1e4358163b
commit 483bb79de8
@@ -211,23 +211,12 @@ class DataSourceWithBackend<
// Use the new query service for explore
if (config.featureToggles.queryServiceFromExplore && request.app === CoreApp.Explore) {
// make sure query-service is enabled on the backend
const isQueryServiceEnabled = config.featureToggles.queryService;
const isExperimentalAPIsEnabled = config.featureToggles.grafanaAPIServerWithExperimentalAPIs;
if (!isQueryServiceEnabled && !isExperimentalAPIsEnabled) {
console.warn('feature toggle queryServiceFromExplore also requires the queryService to be running');
} else {
url = `/apis/query.grafana.app/v0alpha1/namespaces/${config.namespace}/query?ds_type=${this.type}`;
}
url = `/apis/query.grafana.app/v0alpha1/namespaces/${config.namespace}/query?ds_type=${this.type}`;
}
// Use the new query service
if (config.featureToggles.queryServiceFromUI) {
if (!(config.featureToggles.queryService || config.featureToggles.grafanaAPIServerWithExperimentalAPIs)) {
console.warn('feature toggle queryServiceFromUI also requires the queryService to be running');
} else {
url = `/apis/query.grafana.app/v0alpha1/namespaces/${config.namespace}/query?ds_type=${this.type}`;
}
url = `/apis/query.grafana.app/v0alpha1/namespaces/${config.namespace}/query?ds_type=${this.type}`;
}
if (hasExpr) {