modify the order of PrometheusHandler (#670)

* modify the order of PrometheusHandler

* modify the order of PrometheusHandler
master
noel 4 years ago committed by GitHub
parent f64fe5eb5e
commit faf4d7e3bb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -109,13 +109,13 @@ func (s *engine) bindRoute(fr featuredRoutes, router httpx.Router, metrics *stat
chain := alice.New(
handler.TracingHandler,
s.getLogHandler(),
handler.PrometheusHandler(route.Path),
handler.MaxConns(s.conf.MaxConns),
handler.BreakerHandler(route.Method, route.Path, metrics),
handler.SheddingHandler(s.getShedder(fr.priority), metrics),
handler.TimeoutHandler(time.Duration(s.conf.Timeout)*time.Millisecond),
handler.RecoverHandler,
handler.MetricHandler(metrics),
handler.PrometheusHandler(route.Path),
handler.MaxBytesHandler(s.conf.MaxBytes),
handler.GunzipHandler,
)

Loading…
Cancel
Save