From 2750a3516a5313f1fee04e7c9aa29189cad73b40 Mon Sep 17 00:00:00 2001 From: Stephanie Hingtgen Date: Fri, 5 Sep 2025 14:36:52 -0600 Subject: [PATCH] Provisioning: Add provisioning api server to clients (#110721) --- pkg/operators/provisioning/config.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pkg/operators/provisioning/config.go b/pkg/operators/provisioning/config.go index 4f48fba8ea9..6c03da5b91b 100644 --- a/pkg/operators/provisioning/config.go +++ b/pkg/operators/provisioning/config.go @@ -153,7 +153,7 @@ func setupFromConfig(cfg *setting.Cfg) (controllerCfg *provisioningControllerCon return nil, fmt.Errorf("folders_server_url is required in [operator] section") } - apiServerURLs := []string{dashboardsServerURL, foldersServerURL} + apiServerURLs := []string{dashboardsServerURL, foldersServerURL, provisioningServerURL} configProviders := make([]apiserver.RestConfigProvider, len(apiServerURLs)) for i, url := range apiServerURLs { @@ -306,6 +306,7 @@ func setupUnifiedStorageClient(cfg *setting.Cfg, tracer tracing.Tracer, resource if address == "" { return nil, fmt.Errorf("grpc_address is required in [unified_storage] section") } + // FIXME: These metrics are not going to show up in /metrics registry := prometheus.NewPedanticRegistry() conn, err := unified.GrpcConn(address, registry) if err != nil { @@ -316,7 +317,10 @@ func setupUnifiedStorageClient(cfg *setting.Cfg, tracer tracing.Tracer, resource indexConn := conn indexAddress := unifiedStorageSec.Key("grpc_index_address").String() if indexAddress != "" { - indexConn, err = unified.GrpcConn(indexAddress, registry) + // FIXME: These metrics are not going to show up in /metrics. We will also need to wrap these metrics + // to start with something else so it doesn't collide with the storage api metrics. + registry2 := prometheus.NewPedanticRegistry() + indexConn, err = unified.GrpcConn(indexAddress, registry2) if err != nil { return nil, fmt.Errorf("create unified storage index gRPC connection: %w", err) }