added prometheus route
This commit is contained in:
parent
d90baca788
commit
57e252ce2b
@ -5,6 +5,7 @@ import (
|
|||||||
|
|
||||||
"github.com/elazarl/go-bindata-assetfs"
|
"github.com/elazarl/go-bindata-assetfs"
|
||||||
"github.com/gorilla/context"
|
"github.com/gorilla/context"
|
||||||
|
"github.com/prometheus/client_golang/prometheus"
|
||||||
)
|
)
|
||||||
|
|
||||||
var prefix map[string]string
|
var prefix map[string]string
|
||||||
@ -50,5 +51,7 @@ func addRoutes(sm *http.ServeMux, a *Allowances, staticFiles string) {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sm.Handle("/metrics", prometheus.Handler())
|
||||||
|
|
||||||
context.ClearHandler(sm)
|
context.ClearHandler(sm)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user