Unverified Commit d78e9e97 authored by Julien Pivotto's avatar Julien Pivotto Committed by GitHub
Browse files

Merge pull request #8729 from code1305/azure-sd-errfix

return right error if any target creation fails
parents 80545bfb 9c705ffd
......@@ -373,7 +373,7 @@ func (d *Discovery) refresh(ctx context.Context) ([]*targetgroup.Group, error) {
var tg targetgroup.Group
for tgt := range ch {
if tgt.err != nil {
return nil, errors.Wrap(err, "unable to complete Azure service discovery")
return nil, errors.Wrap(tgt.err, "unable to complete Azure service discovery")
if tgt.labelSet != nil {
tg.Targets = append(tg.Targets, tgt.labelSet)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment