feat(metrics): change active alerts to guage

This commit is contained in:
bergquist
2016-11-29 16:46:25 +01:00
parent 7e831e10a2
commit 360516ed41
3 changed files with 47 additions and 44 deletions
+4
View File
@@ -69,6 +69,10 @@ func GetInternalMetrics(c *middleware.Context) Response {
metricName := m.Name() + m.StringifyTags()
switch metric := m.(type) {
case metrics.Gauge:
resp[metricName] = map[string]interface{}{
"value": metric.Value(),
}
case metrics.Counter:
resp[metricName] = map[string]interface{}{
"count": metric.Count(),