mirror of
https://github.com/prometheus-community/postgres_exporter
synced 2025-04-07 09:41:52 +00:00
Merge pull request #724 from roidelapluie/gauge1
Set gauge to 1 when collector is successful
This commit is contained in:
commit
9bd9d83d73
@ -114,6 +114,7 @@ func handleProbe(logger log.Logger) http.HandlerFunc {
|
||||
|
||||
duration := time.Since(start).Seconds()
|
||||
probeDurationGauge.Set(duration)
|
||||
probeSuccessGauge.Set(1)
|
||||
|
||||
// TODO check success, etc
|
||||
h := promhttp.HandlerFor(registry, promhttp.HandlerOpts{})
|
||||
|
Loading…
Reference in New Issue
Block a user