Documentation ¶
Overview ¶
Package pprof serves via its HTTP server runtime profiling data in the format expected by the pprof visualization tool.
See Go's net/http/pprof for docs.
This is a fork of net/http/pprof that doesn't use init side effects and doesn't use html/template (which ends up calling reflect.Value.MethodByName, which disables some linker deadcode optimizations).
Index ¶
- func AddHandlers(mux *http.ServeMux)
- func Cmdline(w http.ResponseWriter, r *http.Request)
- func Handler(name string) http.Handler
- func Index(w http.ResponseWriter, r *http.Request)
- func Profile(w http.ResponseWriter, r *http.Request)
- func Symbol(w http.ResponseWriter, r *http.Request)
- func Trace(w http.ResponseWriter, r *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddHandlers ¶
func Cmdline ¶
func Cmdline(w http.ResponseWriter, r *http.Request)
Cmdline responds with the running program's command line, with arguments separated by NUL bytes. The package initialization registers it as /debug/pprof/cmdline.
func Index ¶
func Index(w http.ResponseWriter, r *http.Request)
Index responds with the pprof-formatted profile named by the request. For example, "/debug/pprof/heap" serves the "heap" profile. Index responds to a request for "/debug/pprof/" with an HTML page listing the available profiles.
func Profile ¶
func Profile(w http.ResponseWriter, r *http.Request)
Profile responds with the pprof-formatted cpu profile. Profiling lasts for duration specified in seconds GET parameter, or for 30 seconds if not specified. The package initialization registers it as /debug/pprof/profile.
Types ¶
This section is empty.