MCPcopy Create free account
hub / github.com/devfeel/dotweb / showPProf

Function showPProf

dotweb_sysgroup.go:26–30  ·  view source on GitHub ↗

query pprof debug info key:heap goroutine threadcreate block

(ctx Context)

Source from the content-addressed store, hash-verified

24// query pprof debug info
25// key:heap goroutine threadcreate block
26func showPProf(ctx Context) error {
27 querykey := ctx.GetRouterName("key")
28 runtime.GC()
29 return pprof.Lookup(querykey).WriteTo(ctx.Response().Writer(), 1)
30}
31
32func freeMemory(ctx Context) error {
33 debug.FreeOSMemory()

Callers

nothing calls this directly

Calls 4

GCMethod · 0.80
WriterMethod · 0.80
GetRouterNameMethod · 0.65
ResponseMethod · 0.65

Tested by

no test coverage detected