Commit Graph

72 Commits

Author SHA1 Message Date
Wang Guoliang 156ee1e04e should use time.Since instead of time.Now().Sub
Kubernetes-commit: 89669283fe84619f0c15af8495ccb28a752bb1e8
2018-02-11 21:17:00 +08:00
Martin Vladev 3c79460222 Register Prometheus etcdmetrics only for apiserver
Removed automatic registration with `init` funciton and use `Register` function
to register metrics for etcd storage only when requested.

Kubernetes-commit: 40cf7880135b56e2d88a04d5fce08303b249eb34
2018-04-20 17:19:13 +03:00
Di Xu 9beeb59216 fix all the typos across the project
Kubernetes-commit: 48388fec7eaad4ac8d84fbe20673ffacf41964a1
2018-02-09 14:53:53 +08:00
Nikhita Raghunath 2cc4871e76 Collect prometheus metrics for custom resources
Since we have a custom handler for apiextensions-apiserver,
we need to record the metrics here.

Kubernetes-commit: 74cd45fb21b349dd037e3bfd844459ca5834cca1
2017-12-28 14:36:31 +05:30
halfcrazy 6f8c3a80da fix typo in package apiserver
Kubernetes-commit: 0da91a8577ddfdeaff985cbb6c0da69d5a2ffc81
2018-02-01 03:04:33 +08:00
Marek Grabowski f2c38580dc Add a metric to track usage of inflight request limit.
Kubernetes-commit: 000d7bac29b9239a29531a526d382394d8d60353
2018-01-16 15:48:20 +00:00
Marek Grabowski d8aa7399d2 Add apiserver metric for number of requests dropped by 'inflight-request' filters.
Kubernetes-commit: 32c66c2b56afe0c716169d9705f84172155ddbb4
2018-01-16 15:48:20 +00:00
hzxuzhonghu 15434cbd47 move prometheus init to k8s.io/apiserver/pkg/endpoints/metrics/metrics.go
Kubernetes-commit: 631119a7d65e01e48b5d8a46d7300b20c65262e1
2018-01-16 15:28:16 +08:00
Clayton Coleman 4175a07239 Track gauge of all long running API requests
Allows a caller to know how many exec, log, proxy, and watch calls are
running at the current moment.

Kubernetes-commit: fabce1b893f96bdf466c1fdb1fcf825210c008ae
2017-09-19 20:35:29 -04:00
Clayton Coleman 1caba4b96e Collapse all metrics handlers into common code
Remove the MonitorRequest method and replace with a method that takes
request.RequestInfo, which is our default way to talk about API objects.
Preserves existing semantics for calls.

Kubernetes-commit: 10e6dc5ed3573118c56fa8823b387e47c8e8ae06
2017-09-11 14:53:18 -04:00
Kubernetes Publisher 8fc21589fe Increase sliding window to 5hr for request_latencies metric
Kubernetes-commit: e1ba3da16c9bebccb3902952d56b59f2e2dbb900
2017-09-22 11:42:05 +00:00
Kubernetes Publisher 7727b5a3a8 Report scope on all apiserver metrics
Counting list of namespaces is != list across all namespaces (same for
latency)

Kubernetes-commit: 545aba778d5d039a3b8a0f0939fdf8f8261ae1a8
2017-09-22 11:42:04 +00:00
Kubernetes Publisher 4c578f11a1 Normalize WATCHLIST to WATCH in metrics
This causes confusion and doesn't match what we authorize on

Kubernetes-commit: 5e46d5b5450f7e7db87e860440f1bb1f8f523ffa
2017-09-22 11:42:04 +00:00
Shyam Jeedigunta d156370a82 Add apiserver metric for response sizes split by namespace scope
Kubernetes-commit: 5facb62806a7f5d442bff8f77418b53cd58544f9
2017-07-29 13:55:24 +00:00
Clayton Coleman c521c8f6b5 Record 429 and timeout errors to prometheus
Allows gathering of load being shed.

Kubernetes-commit: 2e33a2f0bc8ac82aecadcb19cf6e41259454d182
2017-07-16 04:08:41 +00:00
Clayton Coleman 2f49bbbf91 Subresources are not included in apiserver prometheus metrics
Subresources are very often completely different code paths and errors
generated on those code paths are important to distinguish.

Kubernetes-commit: ad431c454c1306fdcc2134a3626444984d350f46
2017-06-13 20:47:28 +00:00
Shyam Jeedigunta b10ed3c56c Copy static variable 'verb' before instrumenting APIserver call to prevent overwriting
Kubernetes-commit: 4d457f55f4b190012440c8a454a2aee338a42c4d
2017-05-19 17:28:21 +00: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
deads2k 1b0d4c5781 tweak a list to a watch verb when requested 2017-02-23 09:48:09 -05:00
Dr. Stefan Schimanski dc90e9a003 genericapiserver: move packages
Towards a sane k8s.io/apiserver package structure.
2017-01-19 10:27:27 -05:00