Chore: Add tracing to team service (#86999)

* add tracing to team service

* another test fix

* pass in context for team creation and membership checking
This commit is contained in:
Ieva
2024-04-29 11:32:03 +01:00
committed by GitHub
parent fbaa847a3c
commit cee713e34c
13 changed files with 107 additions and 36 deletions

View File

@@ -25,6 +25,7 @@ import (
"k8s.io/client-go/rest"
"github.com/grafana/grafana/pkg/infra/localcache"
"github.com/grafana/grafana/pkg/infra/tracing"
"github.com/grafana/grafana/pkg/server"
"github.com/grafana/grafana/pkg/services/apiserver/endpoints/request"
"github.com/grafana/grafana/pkg/services/auth/identity"
@@ -392,7 +393,7 @@ func (c K8sTestHelper) createTestUsers(orgName string) OrgUsers {
c.env.Cfg.AutoAssignOrg = true
c.env.Cfg.AutoAssignOrgId = int(orgId)
teamSvc, err := teamimpl.ProvideService(store, c.env.Cfg)
teamSvc, err := teamimpl.ProvideService(store, c.env.Cfg, tracing.InitializeTracerForTest())
require.NoError(c.t, err)
cache := localcache.ProvideService()