From 337a0fa1073df4f8e3c7111739c023bbacfc5c9e Mon Sep 17 00:00:00 2001 From: Yusuke Kato Date: Fri, 3 Mar 2023 15:09:29 +0900 Subject: [PATCH] bugfix backoff metrics (#1958) Signed-off-by: kpango --- internal/backoff/backoff.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/backoff/backoff.go b/internal/backoff/backoff.go index 7900577927..b11c9f2fca 100644 --- a/internal/backoff/backoff.go +++ b/internal/backoff/backoff.go @@ -157,7 +157,7 @@ func (b *backoff) Do(ctx context.Context, f func(ctx context.Context) (val inter log.Errord("[backoff]\tfor: "+name+",\terror: "+err.Error(), info.Get()) } // e.g. name = vald.v1.Exists/ip ...etc - if name == "" { + if name != "" { mu.Lock() metrics[name] += 1 mu.Unlock()