Add pprof debug server

This commit is contained in:
Richard Patel 2018-11-05 21:39:15 +01:00
parent 77cb45dbec
commit e39565377e
No known key found for this signature in database
GPG Key ID: C268B2BBDA2ABECB

View File

@ -4,6 +4,9 @@ import (
"context"
"github.com/sirupsen/logrus"
"github.com/urfave/cli"
"log"
"net/http"
_ "net/http/pprof"
"net/url"
"os"
"strings"
@ -33,6 +36,9 @@ func init() {
func main() {
app.Run(os.Args)
go func() {
log.Println(http.ListenAndServe("localhost:42069", nil))
}()
}
func cmdCrawler(clic *cli.Context) error {