summaryrefslogtreecommitdiffstats
path: root/configd
diff options
context:
space:
mode:
authorArne Juul <arnej@yahoo-inc.com>2017-12-06 14:50:45 +0000
committerArne Juul <arnej@yahoo-inc.com>2017-12-07 11:02:00 +0000
commita75cbd9c47b246bbb3bf26652d674eb3aa8eb06f (patch)
treecba66a8afeb1bac2e74b1578d8c9346ad3c80c86 /configd
parent6a2f714b2a740a05a709e290079fd18014244462 (diff)
add compulsory description for metrics
Diffstat (limited to 'configd')
-rw-r--r--configd/src/apps/sentinel/metrics.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/configd/src/apps/sentinel/metrics.cpp b/configd/src/apps/sentinel/metrics.cpp
index bc9d87d0e73..df1b0076001 100644
--- a/configd/src/apps/sentinel/metrics.cpp
+++ b/configd/src/apps/sentinel/metrics.cpp
@@ -20,11 +20,16 @@ StartMetrics::StartMetrics()
totalRestartsLastPeriod(1),
startedTime(time(nullptr)),
lastLoggedTime(startedTime - 55),
- sentinel_restarts(metrics->counter("sentinel.restarts")),
- sentinel_totalRestarts(metrics->gauge("sentinel.totalRestarts")),
- sentinel_running(metrics->gauge("sentinel.running")),
- sentinel_uptime(metrics->gauge("sentinel.uptime"))
+ sentinel_restarts(metrics->counter("sentinel.restarts",
+ "how many times sentinel restarted a service")),
+ sentinel_totalRestarts(metrics->gauge("sentinel.totalRestarts",
+ "how many times sentinel restarted a service since sentinel start")),
+ sentinel_running(metrics->gauge("sentinel.running",
+ "how many services the sentinel has running currently")),
+ sentinel_uptime(metrics->gauge("sentinel.uptime",
+ "how many seconds has the sentinel been running"))
{
+ // account for the sentinel itself restarting
sentinel_restarts.add();
}