Commit Graph

10 Commits

Author SHA1 Message Date
kkkkun 6bb07771dd Fix bug: Specical GET should be transformed to WATCH
Kubernetes-commit: 5f98d8f79855af648a610b21d71583a6540a58cd
2021-11-04 21:33:30 +08:00
Abu Kashem 6013da2b94 apiserver: wrap ResponseWriter using abstraction
Kubernetes-commit: 0d50c969c587c8a6c16e0962118305ac652c5a6b
2021-09-20 11:21:56 -04:00
wojtekt c6719af51e Fix metrics reporting for the deprecated watch path
Kubernetes-commit: d9d41b70f64da65525d769ab279e3930d59435fe
2021-08-05 16:17:13 +02:00
Harry Zhang 0321f0c67e fix CleanScope so we can resolve correct verb for apiserver_request_terminations_total
Kubernetes-commit: a3f57886a267c28d5a0193ca7193d4de9e9212d9
2021-07-07 19:07:49 -07:00
Han Kang 1cd0838bc2 bump apiserver_request_total to STABLE status
We've dropped the content-type field since it is effectively unbounded
(we had a sec-vuln about this before actually). We retain all other
fields, despite their unboundedness due to the fact that we can now
explicitly set bounds on label values.

Change-Id: Icc483fc6a17ea6382928f4448643cda6f3e21adb

Kubernetes-commit: cfd00de6866e636332bdcd3f46d6d2ffd8d2bc88
2021-03-04 07:52:00 -08:00
Han Kang 64913bcbc2 fix a number of unbounded dimensions in request metrics (#89451)
* fix a number of unbounded dimensions in request metrics

* add test suite for cleanVerb and cleanContentType

* Properly validate that the content-type and charset (if applicable) are RFC compliant

* add additional test case

* truncate list of content-types

Change-Id: Ia5fe0d2e2c602e4def4b8e0849cc19f3f9251818

Kubernetes-commit: 6c588c3f441252f42fd37526297ed92d1e1f3acf
2020-05-29 08:29:03 +00:00
Han Kang fe6033d4a2 remove client label from apiserver request count metric since it is unbounded
Change-Id: I3a9eacebc9d9dc9ed6347260d9378cdcb5743431

Kubernetes-commit: cc3190968b1f14ddf4067abef849fc41bd6068dc
2020-01-29 12:25:55 -08:00
Matt Liggett 3b01985067 Use regexp instead of substring to do search and replace.
enisoc pointed out how ToLower can change (lengthen even!) the length of
a string given arbitrary input.

Kubernetes-commit: fe202fcfc47c7e0fa7d75dc933c9988bb5a53e5e
2017-04-17 20:35:48 +00:00
Matt Liggett 6c87ad1f20 Drop leading path of KUBECTL.EXE if it shows up in User-Agent.
Kubernetes-commit: 4cff7c3d30f4f6b4377d52ec29ec4866f1d28bb9
2017-04-14 20:35:35 +00:00
Dominik Schulz 37527becd4 Clean user agent
This commit cleans common browser user-agents to reduce the metrics
cardinality in exported prometheus metrics.

Kubernetes-commit: b5c89a8be68e031e12d6750ed6cc470de4cc3fdf
2017-03-18 19:56:09 +00:00