mirror of
https://github.com/hay-kot/homebox.git
synced 2024-11-25 10:05:43 +00:00
d151d42081
* reorg + pprof endpoints * fix spacing issue * fix generation directory
16 lines
412 B
Go
16 lines
412 B
Go
package debughandlers
|
|
|
|
import (
|
|
"expvar"
|
|
"net/http"
|
|
"net/http/pprof"
|
|
)
|
|
|
|
func New(mux *http.ServeMux) {
|
|
mux.HandleFunc("/debug/pprof", pprof.Index)
|
|
mux.HandleFunc("/debug/pprof/cmdline", pprof.Cmdline)
|
|
mux.HandleFunc("/debug/pprof/profile", pprof.Profile)
|
|
mux.HandleFunc("/debug/pprof/symbol", pprof.Symbol)
|
|
mux.HandleFunc("/debug/pprof/trace", pprof.Trace)
|
|
mux.Handle("/debug/vars", expvar.Handler())
|
|
}
|