diff options
author | hanemile <hanemile@protonmail.com> | 2019-01-23 20:25:44 +0100 |
---|---|---|
committer | hanemile <hanemile@protonmail.com> | 2019-01-23 20:25:44 +0100 |
commit | 48451fa85af62d28bfb9257ae8c2b05cecea80fe (patch) | |
tree | 907650e33b02281f0d926ec1e696a4bbe39c93b8 /metrics.go | |
parent | e1ec6a26489b311ca5368fd227b527e6591882ee (diff) |
push before using everything in docker swarm
Diffstat (limited to 'metrics.go')
-rw-r--r-- | metrics.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/metrics.go b/metrics.go index 5881c64..5d04517 100644 --- a/metrics.go +++ b/metrics.go @@ -16,6 +16,10 @@ func metricHandler(w http.ResponseWriter, r *http.Request) { metricsString += fmt.Sprintf("galaxy_star_count{galaxy_nr=\"%d\"} %d\n", i, starCount[i]) } + for i := 0; i < len(errorCount); i++ { + metricsString += fmt.Sprintf("galaxy_error_count{galaxy_nr=\"%d\"} %d\n", i, errorCount[i]) + } + log.Println(metricsString) _, _ = fmt.Fprintf(w, metricsString) } |