Skip to content

Commit 374972f

Browse files
Do not include "code" for latency
This created to much noise and broke BC.
1 parent 96e2b22 commit 374972f

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

pkg/webhook/internal/metrics/metrics.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ var (
3030
Name: "controller_runtime_webhook_latency_seconds",
3131
Help: "Histogram of the latency of processing admission requests",
3232
},
33-
[]string{"webhook", "code"},
33+
[]string{"webhook"},
3434
)
3535

3636
// RequestTotal is a prometheus metric which is a counter of the total processed admission requests.

pkg/webhook/server.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,6 @@ func instrumentedHook(path string, hookRaw http.Handler) http.Handler {
131131
gge := metrics.RequestInFlight.With(lbl)
132132

133133
// Initialize the most likely HTTP status codes.
134-
lat.WithLabelValues("200")
135-
lat.WithLabelValues("500")
136134
cnt.WithLabelValues("200")
137135
cnt.WithLabelValues("500")
138136

0 commit comments

Comments
 (0)