mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-05 02:09:56 +00:00
Normalize WATCHLIST to WATCH in metrics
This causes confusion and doesn't match what we authorize on
This commit is contained in:
parent
2a9c8df2ec
commit
5e46d5b545
@ -106,6 +106,10 @@ func MonitorRequest(request *http.Request, verb, resource, subresource, scope, c
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// normalize the legacy WATCHLIST to WATCH to ensure users aren't surprised by metrics
|
||||||
|
if verb == "WATCHLIST" {
|
||||||
|
reportedVerb = "WATCH"
|
||||||
|
}
|
||||||
|
|
||||||
client := cleanUserAgent(utilnet.GetHTTPClient(request))
|
client := cleanUserAgent(utilnet.GetHTTPClient(request))
|
||||||
Monitor(reportedVerb, resource, subresource, scope, client, contentType, httpCode, respSize, reqStart)
|
Monitor(reportedVerb, resource, subresource, scope, client, contentType, httpCode, respSize, reqStart)
|
||||||
|
Loading…
Reference in New Issue
Block a user