Skip to content

Commit 8d08803

Browse files
authored
Add pprof cpu profiler (#3105)
We are observing a situation where the agent is under so much contention that it is not able to operate, and we need to observe what it is doing.
2 parents 9e64bae + 8ee0478 commit 8d08803

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

main.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,7 @@ func mainWithExitCode() flags.ExitCode {
303303
mux.HandleFunc("/debug/pprof/", pprof.Index)
304304
mux.HandleFunc("/debug/pprof/symbol", pprof.Symbol)
305305
mux.HandleFunc("/debug/pprof/trace", pprof.Trace)
306+
mux.HandleFunc("/debug/pprof/profile", pprof.Profile)
306307
//nolint:gosec
307308
if err = http.ListenAndServe(f.HTTPAddress, mux); err != nil {
308309
log.Errorf("Serving pprof on %s failed: %s", f.HTTPAddress, err)

0 commit comments

Comments
 (0)