Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--internal/source/gitlab/cache/cache.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/internal/source/gitlab/cache/cache.go b/internal/source/gitlab/cache/cache.go
index c5340af9..d569b81b 100644
--- a/internal/source/gitlab/cache/cache.go
+++ b/internal/source/gitlab/cache/cache.go
@@ -83,12 +83,14 @@ func (c *Cache) Resolve(ctx context.Context, domain string) *api.Lookup {
return entry.Lookup()
}
- metrics.DomainsSourceCacheMiss.Inc()
if entry.NeedsRefresh() {
c.Refresh(entry)
+
+ metrics.DomainsSourceCacheHit.Inc()
return entry.Lookup()
}
+ metrics.DomainsSourceCacheMiss.Inc()
return c.retrieve(ctx, entry)
}