Skip to content

Commit

Permalink
Bind pprof cpu profiles correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
turt2live committed Aug 26, 2023
1 parent 5922c4d commit abef43e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/_debug/pprof.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ func BindPprofEndpoints(httpMux *httprouter.Router, secret string) {
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/goroutine", pprofServe(pprof.Index, secret))
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/heap", pprofServe(pprof.Index, secret))
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/mutex", pprofServe(pprof.Index, secret))
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/profile", pprofServe(pprof.Index, secret))
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/profile", pprofServe(pprof.Profile, secret))
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/threadcreate", pprofServe(pprof.Index, secret))
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/trace", pprofServe(pprof.Index, secret))
httpMux.Handler("GET", "/_matrix/media/unstable/io.t2bot/debug/pprof/trace", pprofServe(pprof.Trace, secret))
}

type generatorFn = func(w http.ResponseWriter, r *http.Request)
Expand Down

0 comments on commit abef43e

Please sign in to comment.