From 4dd589feddbec941e13589ad7ec90b56d63e3a1a Mon Sep 17 00:00:00 2001 From: Hugo Vicente Date: Fri, 28 Aug 2026 13:37:05 +0000 Subject: [PATCH] chore: Remove stale metrics timeout TODO Removes the stale metrics timeout TODO. Go 1.22+ already adjusts pprof write deadlines for the requested profile duration. Addresses: [#1733](https://github.com/cloudflare/cloudflared/issues/1733) --- metrics/metrics.go | 2 -- 1 file changed, 2 deletions(-) diff --git a/metrics/metrics.go b/metrics/metrics.go index de6cad56..abc62504 100644 --- a/metrics/metrics.go +++ b/metrics/metrics.go @@ -149,8 +149,6 @@ func ServeMetrics( var wg sync.WaitGroup // Metrics port is privileged, so no need for further access control trace.AuthRequest = func(*http.Request) (bool, bool) { return true, true } - // TODO: parameterize ReadTimeout and WriteTimeout. The maximum time we can - // profile CPU usage depends on WriteTimeout h := newMetricsHandler(config, log) server := &http.Server{ ReadTimeout: 10 * time.Second,