Compare commits
2 Commits
database/i
...
rpc/v0.0.9
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ce77bd094d | ||
|
|
6f251c9fb7 |
@@ -23,10 +23,10 @@ require (
|
||||
github.com/olekukonko/tablewriter v0.0.5
|
||||
github.com/spf13/cobra v1.8.1
|
||||
github.com/tx7do/kratos-bootstrap/api v0.0.8
|
||||
github.com/tx7do/kratos-bootstrap/config v0.0.7
|
||||
github.com/tx7do/kratos-bootstrap/logger v0.0.7
|
||||
github.com/tx7do/kratos-bootstrap/registry v0.0.7
|
||||
github.com/tx7do/kratos-bootstrap/tracer v0.0.5
|
||||
github.com/tx7do/kratos-bootstrap/config v0.0.8
|
||||
github.com/tx7do/kratos-bootstrap/logger v0.0.8
|
||||
github.com/tx7do/kratos-bootstrap/registry v0.0.8
|
||||
github.com/tx7do/kratos-bootstrap/tracer v0.0.8
|
||||
github.com/tx7do/kratos-bootstrap/utils v0.1.2
|
||||
golang.org/x/tools v0.27.0
|
||||
)
|
||||
|
||||
21
rpc/rest.go
21
rpc/rest.go
@@ -104,15 +104,16 @@ func initRestConfig(cfg *conf.Bootstrap, mds ...middleware.Middleware) []kratosR
|
||||
|
||||
func registerHttpPprof(s *kratosRest.Server) {
|
||||
s.HandleFunc("/debug/pprof", pprof.Index)
|
||||
s.HandleFunc("/debug/pprof/cmdline", pprof.Cmdline)
|
||||
s.HandleFunc("/debug/pprof/profile", pprof.Profile)
|
||||
s.HandleFunc("/debug/pprof/symbol", pprof.Symbol)
|
||||
s.HandleFunc("/debug/pprof/trace", pprof.Trace)
|
||||
|
||||
s.HandleFunc("/debug/pprof/allocs", pprof.Handler("allocs").ServeHTTP)
|
||||
s.HandleFunc("/debug/pprof/block", pprof.Handler("block").ServeHTTP)
|
||||
s.HandleFunc("/debug/pprof/goroutine", pprof.Handler("goroutine").ServeHTTP)
|
||||
s.HandleFunc("/debug/pprof/heap", pprof.Handler("heap").ServeHTTP)
|
||||
s.HandleFunc("/debug/pprof/mutex", pprof.Handler("mutex").ServeHTTP)
|
||||
s.HandleFunc("/debug/pprof/threadcreate", pprof.Handler("threadcreate").ServeHTTP)
|
||||
s.HandleFunc("/debug/cmdline", pprof.Cmdline)
|
||||
s.HandleFunc("/debug/profile", pprof.Profile)
|
||||
s.HandleFunc("/debug/symbol", pprof.Symbol)
|
||||
s.HandleFunc("/debug/trace", pprof.Trace)
|
||||
|
||||
s.HandleFunc("/debug/allocs", pprof.Handler("allocs").ServeHTTP)
|
||||
s.HandleFunc("/debug/block", pprof.Handler("block").ServeHTTP)
|
||||
s.HandleFunc("/debug/goroutine", pprof.Handler("goroutine").ServeHTTP)
|
||||
s.HandleFunc("/debug/heap", pprof.Handler("heap").ServeHTTP)
|
||||
s.HandleFunc("/debug/mutex", pprof.Handler("mutex").ServeHTTP)
|
||||
s.HandleFunc("/debug/threadcreate", pprof.Handler("threadcreate").ServeHTTP)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user