Plugins: Add termination stage to plugin loader pipeline (#72822)
* add termination stage * uid -> pluginID (for now) * also fix fakes * add simple test * Fix logger name Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com> * inline stop func call Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com> --------- Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com>
This commit is contained in:
co-authored by
Giuseppe Guerra
parent
7bc6d32eb9
commit
60b4a0b2a4
@@ -65,6 +65,10 @@ func (b *Bootstrap) Bootstrap(ctx context.Context, src plugins.PluginSource, fou
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if len(b.decorateSteps) == 0 {
|
||||
return ps, nil
|
||||
}
|
||||
|
||||
for _, p := range ps {
|
||||
for _, decorator := range b.decorateSteps {
|
||||
p, err = decorator(ctx, p)
|
||||
|
||||
Reference in New Issue
Block a user