Skip to content

Commit

Permalink
WFE: Track in-flight for "/" (#7759)
Browse files Browse the repository at this point in the history
  • Loading branch information
beautifulentropy authored Oct 18, 2024
1 parent d0c9aa3 commit 71178f4
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions metrics/measured_http/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,8 @@ func (h *MeasuredHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
rwws := &responseWriterWithStatus{w, 0}

subHandler, pattern := h.Handler(r)
if pattern != "/" {
h.inFlightRequestsGauge.WithLabelValues(pattern).Inc()
defer h.inFlightRequestsGauge.WithLabelValues(pattern).Dec()
}
h.inFlightRequestsGauge.WithLabelValues(pattern).Inc()
defer h.inFlightRequestsGauge.WithLabelValues(pattern).Dec()

// Use the method string only if it's a recognized HTTP method. This avoids
// ballooning timeseries with invalid methods from public input.
Expand Down

0 comments on commit 71178f4

Please sign in to comment.