Add pprof comment

This commit is contained in:
tidwall 2019-03-04 10:44:53 -07:00
parent 07a5c2111c
commit 72b5d8f50f
1 changed files with 15 additions and 0 deletions

View File

@ -42,12 +42,27 @@ var (
// TODO: Set to false in 2.* // TODO: Set to false in 2.*
var httpTransport = true var httpTransport = true
////////////////////////////////////////////////////////////////////////////////
//
// Fire up a webhook test server by using the --webhook-http-consumer-port // Fire up a webhook test server by using the --webhook-http-consumer-port
// for example // for example
// $ ./tile38-server --webhook-http-consumer-port 9999 // $ ./tile38-server --webhook-http-consumer-port 9999
// //
// The create hooks like such... // The create hooks like such...
// SETHOOK myhook http://localhost:9999/myhook NEARBY mykey FENCE POINT 33.5 -115.5 1000 // SETHOOK myhook http://localhost:9999/myhook NEARBY mykey FENCE POINT 33.5 -115.5 1000
//
////////////////////////////////////////////////////////////////////////////////
//
// Memory profiling - start the server with the -pprofport flag
//
// $ ./tile38-server -pprofport 6060
//
// Then, at any point, from a different terminal execute:
// $ go tool pprof -svg http://localhost:6060/debug/pprof/heap > out.svg
//
// Load the SVG into a web browser to visualize the memory usage
//
////////////////////////////////////////////////////////////////////////////////
type hserver struct{} type hserver struct{}