Set ContinueOnError for prometheus http handler.

This commit is contained in:
Random-Liu 2017-06-20 11:56:21 -07:00
parent 689b91c1f2
commit 66c95c765f

View File

@ -100,7 +100,7 @@ func RegisterPrometheusHandler(mux httpmux.Mux, containerManager manager.Manager
prometheus.NewGoCollector(),
prometheus.NewProcessCollector(os.Getpid(), ""),
)
mux.Handle(prometheusEndpoint, promhttp.HandlerFor(r, promhttp.HandlerOpts{}))
mux.Handle(prometheusEndpoint, promhttp.HandlerFor(r, promhttp.HandlerOpts{ErrorHandling: promhttp.ContinueOnError}))
}
func staticHandlerNoAuth(w http.ResponseWriter, r *http.Request) {