mirror of
https://github.com/containous/traefik.git
synced 2025-03-12 20:58:23 +03:00
Call functions to enable block/mutex pprof profiles.
This commit is contained in:
parent
689f120410
commit
0c0ecc1cdc
@ -38,6 +38,8 @@ func (g DebugHandler) AddRoutes(router *mux.Router) {
|
||||
fmt.Fprint(w, "\n}\n")
|
||||
})
|
||||
|
||||
runtime.SetBlockProfileRate(1)
|
||||
runtime.SetMutexProfileFraction(5)
|
||||
router.Methods(http.MethodGet).PathPrefix("/debug/pprof/cmdline").HandlerFunc(pprof.Cmdline)
|
||||
router.Methods(http.MethodGet).PathPrefix("/debug/pprof/profile").HandlerFunc(pprof.Profile)
|
||||
router.Methods(http.MethodGet).PathPrefix("/debug/pprof/symbol").HandlerFunc(pprof.Symbol)
|
||||
|
Loading…
x
Reference in New Issue
Block a user