From eb45d60228b4847c14a5fba948993d34656a05df Mon Sep 17 00:00:00 2001 From: Dave Protasowski Date: Wed, 3 Sep 2025 17:12:44 -0400 Subject: [PATCH] OTel docs follow up (#6360) * include UCUM link * address Evan's OTel Docs feedback * include autoscaler attributes --- .../observability/metrics/serving-metrics.md | 45 +++++++++++-------- docs/snippets/observability-shared-metrics.md | 16 +++---- 2 files changed, 35 insertions(+), 26 deletions(-) diff --git a/docs/serving/observability/metrics/serving-metrics.md b/docs/serving/observability/metrics/serving-metrics.md index 61ebdc842..8228ea2e2 100644 --- a/docs/serving/observability/metrics/serving-metrics.md +++ b/docs/serving/observability/metrics/serving-metrics.md @@ -22,7 +22,7 @@ requests and user-container behavior. **Instrument Type:** Int64Gauge -**Unit (UCUM):** {item} +**Unit ([UCUM](https://ucum.org)):** {request} **Description:** Number of current items in the queue proxy queue @@ -30,7 +30,7 @@ requests and user-container behavior. **Instrument Type:** Float64Histogram -**Unit (UCUM):** s +**Unit ([UCUM](https://ucum.org)):** s **Description:** The duration of the task execution @@ -43,11 +43,11 @@ The following metrics can help you to understand how an application responds whe **Instrument Type:** Float64Gauge -**Unit (UCUM):** {request} +**Unit ([UCUM](https://ucum.org)):** {request} **Description:** Concurrent requests that are routed to the Activator -The following attributes are included with the metrics below +The following attributes are included with the metric Name | Type | Description -|-|- @@ -60,11 +60,21 @@ Name | Type | Description Autoscaler component exposes a number of metrics related to its decisions per revision. For example, at any given time, you can monitor the desired pods the Autoscaler wants to allocate for a Service, the average number of requests per second during the stable window, or whether autoscaler is in panic mode (KPA). +The following attributes are included with the autoscaling metrics below + +Name | Type | Description +-|-|- +`k8s.namespace.name` | string | Namespace of the Revision +`kn.service.name` | string | Knative Service name associated with this Revision +`kn.configuration.name` | string | Knative Configuration name associated with this Revision +`kn.revision.name` | string | The name of the Revision + + ### `kn.autoscaler.scrape.duration` **Instrument Type:** Float64Histogram -**Unit (UCUM):** s +**Unit ([UCUM](https://ucum.org)):** s **Description:** The duration of scraping the revision @@ -72,7 +82,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Int64Gauge -**Unit (UCUM):** {item} +**Unit ([UCUM](https://ucum.org)):** {pod} **Description:** Number of pods the autoscaler wants to allocate @@ -80,7 +90,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Float64Gauge -**Unit (UCUM):** {concurrency} +**Unit ([UCUM](https://ucum.org)):** {concurrency} **Description:** Excess burst capacity observed over the stable window @@ -88,7 +98,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Float64Gauge -**Unit (UCUM):** {concurrency} +**Unit ([UCUM](https://ucum.org)):** {concurrency} **Description:** Average of request count per observed pod over the stable window @@ -96,7 +106,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Float64Gauge -**Unit (UCUM):** {concurrency} +**Unit ([UCUM](https://ucum.org)):** {concurrency} **Description:** Average of request count per observed pod over the panic window @@ -104,7 +114,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Float64Gauge -**Unit (UCUM):** {concurrency} +**Unit ([UCUM](https://ucum.org)):** {concurrency} **Description:** The desired concurrent requests for each pod @@ -112,7 +122,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Float64Gauge -**Unit (UCUM):** {request}/s +**Unit ([UCUM](https://ucum.org)):** {request}/s **Description:** Average of requests-per-second per observed pod over the stable window @@ -120,16 +130,15 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Float64Gauge -**Unit (UCUM):** {request}/s +**Unit ([UCUM](https://ucum.org)):** {request}/s **Description:** Average of requests-per-second per observed pod over the panic window - ### `kn.revision.pods.requested` **Instrument Type:** Int64Gauge -**Unit (UCUM):** {pod} +**Unit ([UCUM](https://ucum.org)):** {pod} **Description:** Number of pods autoscaler requested from Kubernetes @@ -137,7 +146,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Int64Gauge -**Unit (UCUM):** {pod} +**Unit ([UCUM](https://ucum.org)):** {pod} **Description:** Number of pods that are allocated currently @@ -145,7 +154,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Int64Gauge -**Unit (UCUM):** {pod} +**Unit ([UCUM](https://ucum.org)):** {pod} **Description:** Number of pods that are not ready currently @@ -153,7 +162,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Int64Gauge -**Unit (UCUM):** {pod} +**Unit ([UCUM](https://ucum.org)):** {pod} **Description:** Number of pods that are pending currently @@ -161,7 +170,7 @@ Autoscaler component exposes a number of metrics related to its decisions per re **Instrument Type:** Int64Gauge -**Unit (UCUM):** {pod} +**Unit ([UCUM](https://ucum.org)):** {pod} **Description:** Number of pods that are terminating currently diff --git a/docs/snippets/observability-shared-metrics.md b/docs/snippets/observability-shared-metrics.md index 3069efdf4..604e515fd 100644 --- a/docs/snippets/observability-shared-metrics.md +++ b/docs/snippets/observability-shared-metrics.md @@ -25,7 +25,7 @@ Name | Type | Description | Examples **Instrument Type:** Histogram -**Unit (UCUM):** s +**Unit ([[UCUM](https://ucum.org)):** s **Description:** The duration of task execution. @@ -55,7 +55,7 @@ Name | Type | Description | **Instrument Type:** Int64UpDownCounter -**Unit (UCUM):** {item} +**Unit ([UCUM](https://ucum.org)):** {item} **Description:** Number of current items in the queue @@ -63,7 +63,7 @@ Name | Type | Description | **Instrument Type:** Int64Counter -**Unit (UCUM):** {item} +**Unit ([UCUM](https://ucum.org)):** {item} **Description:** Number of items added to the queue @@ -71,7 +71,7 @@ Name | Type | Description | **Instrument Type:** -**Unit (UCUM):** s +**Unit ([UCUM](https://ucum.org)):** s **Description:** How long an item stays in workqueue @@ -79,7 +79,7 @@ Name | Type | Description | **Instrument Type:** Float64Histogram -**Unit (UCUM):** s +**Unit ([UCUM](https://ucum.org)):** s **Description:** How long in seconds processing an item from workqueue takes @@ -87,7 +87,7 @@ Name | Type | Description | **Instrument Type:** Float64Gauge -**Unit (UCUM):** s +**Unit ([UCUM](https://ucum.org)):** s **Description:** How many seconds of work the reconciler has done that is in progress and hasn't been observed by duration. Large values indicate stuck threads. One can deduce the number of stuck threads by observing the rate at which this increases. @@ -95,7 +95,7 @@ Name | Type | Description | **Instrument Type:** Float64Gauge -**Unit (UCUM):** s +**Unit ([UCUM](https://ucum.org)):** s **Description:** How long the longest worker thread has been running @@ -103,7 +103,7 @@ Name | Type | Description | **Instrument Type:** Int64Counter -**Unit (UCUM):** {item} +**Unit ([UCUM](https://ucum.org)):** {item} **Description:** Number of items re-added to the queue