dump heap
curl -s http://127.0.0.1:8080/debug/pprof/heap > 1231.heap
休息十分钟
curl -s http://127.0.0.1:8080/debug/pprof/heap > 1241.heap
diff
go tool pprof --http :9090 --base 1231.heap 1241.heap
耗费内存最多的并非是泄露的地方,这是一个容易混淆的地方!