aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Ben Kochie <superq@gmail.com> 2016-10-30 10:06:57 +0100
committerGravatar Miek Gieben <miek@miek.nl> 2016-10-30 09:06:57 +0000
commit98a8fb2622d5e6a64782c091952fabd224843ed9 (patch)
treeb9090860b60aed45cc0ba1c04f2beaa72d5ead5f
parent490ffbd6d234430cd63d621ea9ad28202f8a9d1e (diff)
downloadcoredns-98a8fb2622d5e6a64782c091952fabd224843ed9.tar.gz
coredns-98a8fb2622d5e6a64782c091952fabd224843ed9.tar.zst
coredns-98a8fb2622d5e6a64782c091952fabd224843ed9.zip
Update metric names (#371)
Cleanup names/typos to match standard naming conventions.
-rw-r--r--middleware/cache/README.md4
-rw-r--r--middleware/cache/handler.go8
-rw-r--r--middleware/dnssec/README.md4
-rw-r--r--middleware/dnssec/handler.go8
-rw-r--r--middleware/metrics/test/scrape.go2
5 files changed, 13 insertions, 13 deletions
diff --git a/middleware/cache/README.md b/middleware/cache/README.md
index 3a4dea43e..8d068f1a3 100644
--- a/middleware/cache/README.md
+++ b/middleware/cache/README.md
@@ -39,8 +39,8 @@ The minimum TTL allowed on resource records is 5 seconds.
If monitoring is enabled (via the *prometheus* directive) then the following metrics are exported:
-* coredns_cache_size_guage{type} - total elements in the case, type is either "denial" or "success".
-* coredns_cache_capacity_guage{type} - total capacity of the cache, type is either "denial" or "success".
+* coredns_cache_size{type} - total elements in the case, type is either "denial" or "success".
+* coredns_cache_capacity{type} - total capacity of the cache, type is either "denial" or "success".
## Examples
diff --git a/middleware/cache/handler.go b/middleware/cache/handler.go
index 9c3615e80..146ccbc56 100644
--- a/middleware/cache/handler.go
+++ b/middleware/cache/handler.go
@@ -57,15 +57,15 @@ var (
cacheSize = prometheus.NewGaugeVec(prometheus.GaugeOpts{
Namespace: middleware.Namespace,
Subsystem: subsystem,
- Name: "size_guage",
- Help: "Gauge of number of elements in the cache.",
+ Name: "size",
+ Help: "The number of elements in the cache.",
}, []string{"type"})
cacheCapacity = prometheus.NewGaugeVec(prometheus.GaugeOpts{
Namespace: middleware.Namespace,
Subsystem: subsystem,
- Name: "capacity_gauge",
- Help: "Gauge of cache's capacity.",
+ Name: "capacity",
+ Help: "The cache's capacity.",
}, []string{"type"})
)
diff --git a/middleware/dnssec/README.md b/middleware/dnssec/README.md
index 5daebc7f6..810592585 100644
--- a/middleware/dnssec/README.md
+++ b/middleware/dnssec/README.md
@@ -41,7 +41,7 @@ dnssec [ZONES... ] {
If monitoring is enabled (via the *prometheus* directive) then the following metrics are exported:
-* coredns_dnssec_size_guage{type} - total elements in the cache, type is "signature".
-* coredns_dnssec_capacity_guage{type} - total capacity of the cache, type is "signature".
+* coredns_dnssec_cache_size{type} - total elements in the cache, type is "signature".
+* coredns_dnssec_cache_capacity{type} - total capacity of the cache, type is "signature".
## Examples
diff --git a/middleware/dnssec/handler.go b/middleware/dnssec/handler.go
index 1ea981a73..2b7730083 100644
--- a/middleware/dnssec/handler.go
+++ b/middleware/dnssec/handler.go
@@ -43,15 +43,15 @@ var (
cacheSize = prometheus.NewGaugeVec(prometheus.GaugeOpts{
Namespace: middleware.Namespace,
Subsystem: subsystem,
- Name: "size_guage",
- Help: "Gauge of number of elements in the cache.",
+ Name: "cache_size",
+ Help: "The number of elements in the dnssec cache.",
}, []string{"type"})
cacheCapacity = prometheus.NewGaugeVec(prometheus.GaugeOpts{
Namespace: middleware.Namespace,
Subsystem: subsystem,
- Name: "capacity_gauge",
- Help: "Gauge of cache's capacity.",
+ Name: "cache_capacity",
+ Help: "The dnssec cache's capacity.",
}, []string{"type"})
)
diff --git a/middleware/metrics/test/scrape.go b/middleware/metrics/test/scrape.go
index d64bef96f..c748be209 100644
--- a/middleware/metrics/test/scrape.go
+++ b/middleware/metrics/test/scrape.go
@@ -18,7 +18,7 @@
// Basic usage:
//
// result := Scrape("http://localhost:9153/metrics")
-// v := MetricValue("coredns_cache_capacity_gauge", result)
+// v := MetricValue("coredns_cache_capacity", result)
//
package test