Skip to content

Commit ecb4ee3

Browse files
committed
📖 document exposed metrics
Update documentation for the metrics package to enumerate all exposed metrics with an explanation of what they capture.
1 parent 19e72eb commit ecb4ee3

File tree

1 file changed

+46
-1
lines changed

1 file changed

+46
-1
lines changed

pkg/metrics/doc.go

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,51 @@ limitations under the License.
1515
*/
1616

1717
/*
18-
Package metrics contains controller related metrics utilities
18+
Package metrics contains controller related metrics utilities.
19+
20+
Client Metrics
21+
22+
"rest_client_request_latency_seconds" - Request latency in seconds. Broken down by verb and URL.
23+
24+
"rest_client_requests_total" - Number of HTTP requests, partitioned by status code, method, and host.
25+
26+
Reflector Metrics
27+
28+
"reflector_lists_total" - Total number of API lists done by the reflectors.
29+
30+
"reflector_list_duration_seconds" - How long an API list takes to return and decode for the reflectors.
31+
32+
"reflector_items_per_list" - How many items an API list returns to the reflectors.
33+
34+
"reflector_watches_total" - Total number of API watches done by the reflectors.
35+
36+
"reflector_short_watches_total" - Total number of short API watches done by the reflectors.
37+
38+
"reflector_watch_duration_seconds" - How long an API watch takes to return and decode for the reflectors.
39+
40+
"reflector_items_per_watch" - How many items an API watch returns to the reflectors.
41+
42+
"reflector_last_resource_version" - Last resource version seen for the reflectors.
43+
44+
Workqueue Metrics
45+
46+
"workqueue_depth" - Current depth of workqueue
47+
48+
"workqueue_adds_total" - Total number of adds handled by workqueue.
49+
50+
"workqueue_queue_duration_seconds" - How long in seconds an item stays in workqueue before being requested.
51+
52+
"workqueue_work_duration_seconds" - How long in seconds processing an item from workqueue takes.
53+
54+
"workqueue_unfinished_work_seconds" - How many seconds of work has done that
55+
is in progress and hasn't been observed by work_duration. Large
56+
values indicate stuck threads. One can deduce the number of stuck
57+
threads by observing the rate at which this increases.
58+
59+
"workqueue_longest_running_processor_seconds" - How many seconds has the longest running
60+
processor for workqueue been running.
61+
62+
"workqueue_retries_total" - Total number of retries handled by workqueue.
63+
1964
*/
2065
package metrics

0 commit comments

Comments
 (0)