From 47413340e1c865a83d68b058a136cc5e10f00508 Mon Sep 17 00:00:00 2001 From: siddontang Date: Tue, 5 Aug 2014 08:43:04 +0800 Subject: [PATCH] add net http pprof --- cmd/ledis-server/main.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cmd/ledis-server/main.go b/cmd/ledis-server/main.go index 576ab7f..8673cd2 100644 --- a/cmd/ledis-server/main.go +++ b/cmd/ledis-server/main.go @@ -3,6 +3,9 @@ package main import ( "flag" "github.com/siddontang/ledisdb/server" + "log" + "net/http" + _ "net/http/pprof" "os" "os/signal" "runtime" @@ -52,5 +55,9 @@ func main() { app.Close() }() + go func() { + log.Println(http.ListenAndServe("localhost:6060", nil)) + }() + app.Run() }