Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Enable pprof #927

Merged
merged 1 commit into from
Feb 12, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion cmd/fluxd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"fmt"
"io/ioutil"
"net/http"
_ "net/http/pprof"
"os"
"os/exec"
"os/signal"
Expand Down Expand Up @@ -335,7 +336,7 @@ func main() {

// HTTP transport component, for metrics
go func() {
mux := http.NewServeMux()
mux := http.DefaultServeMux
mux.Handle("/metrics", promhttp.Handler())
handler := daemonhttp.NewHandler(daemonRef, daemonhttp.NewRouter())
mux.Handle("/api/flux/", http.StripPrefix("/api/flux", handler))
Expand Down