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:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2019-12-17 15:00:09 +0300
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2019-12-17 15:00:09 +0300
commitb6c55c1fed2f48c75aade7344d57e171fe4f0073 (patch)
tree6b17c5d603adaa8b051c6bd37a11a4ce587a71b1 /metrics/metrics.go
parent332f72f54c95bf44c8559b65473350516827b1c4 (diff)
Add GitLab API domains source caching metrics
Diffstat (limited to 'metrics/metrics.go')
-rw-r--r--metrics/metrics.go14
1 files changed, 14 insertions, 0 deletions
diff --git a/metrics/metrics.go b/metrics/metrics.go
index 18fd3fdd..e65d87b1 100644
--- a/metrics/metrics.go
+++ b/metrics/metrics.go
@@ -28,10 +28,24 @@ var (
Name: "gitlab_pages_last_domain_update_seconds",
Help: "UNIX timestamp of the last update",
})
+
+ // DomainsSourceCacheHit is the number of GitLab API call cache hits
+ DomainsSourceCacheHit = prometheus.NewCounter(prometheus.CounterOpts{
+ Name: "gitlab_pages_domains_source_cache_hit",
+ Help: "The number of GitLab domains API cache hits",
+ })
+
+ // DomainsSourceCacheMiss is the number of GitLab API call cache misses
+ DomainsSourceCacheMiss = prometheus.NewCounter(prometheus.CounterOpts{
+ Name: "gitlab_pages_domains_source_cache_miss",
+ Help: "The number of GitLab domains API cache misses",
+ })
)
func init() {
prometheus.MustRegister(DomainsServed)
prometheus.MustRegister(DomainUpdates)
prometheus.MustRegister(DomainLastUpdateTime)
+ prometheus.MustRegister(DomainsSourceCacheHit)
+ prometheus.MustRegister(DomainsSourceCacheMiss)
}