Add debug headers when downloading plugins (#92579)

This commit is contained in:
Andres Martinez Gotor
2024-08-29 11:30:21 +02:00
committed by GitHub
parent 4209c13155
commit f9cd0fe5d1
8 changed files with 122 additions and 24 deletions

View File

@ -10,6 +10,7 @@ import (
"github.com/grafana/grafana/pkg/infra/log"
"github.com/grafana/grafana/pkg/plugins"
"github.com/grafana/grafana/pkg/plugins/repo"
"github.com/grafana/grafana/pkg/services/featuremgmt"
"github.com/grafana/grafana/pkg/services/pluginsintegration/pluginstore"
"github.com/grafana/grafana/pkg/setting"
@ -107,6 +108,7 @@ func (s *Service) installPlugins(ctx context.Context) error {
s.log.Info("Installing plugin", "pluginId", installPlugin.ID, "version", installPlugin.Version)
start := time.Now()
ctx = repo.WithRequestOrigin(ctx, "preinstall")
err := s.pluginInstaller.Add(ctx, installPlugin.ID, installPlugin.Version, compatOpts)
if err != nil {
var dupeErr plugins.DuplicateError