From 115d11109ebbac4b0bf24a6e889d3ad7dfcddee8 Mon Sep 17 00:00:00 2001 From: Kenta Kozuka Date: Mon, 31 Jul 2023 22:56:36 +0900 Subject: [PATCH] Add prometheus metrics lists to docs (#4533) * Add prometheus metrics lists to docs Signed-off-by: Kenta Kozuka * Add missing metrics Signed-off-by: Kenta Kozuka * Move metric docs to under user guide Signed-off-by: Kenta Kozuka --------- Signed-off-by: Kenta Kozuka Signed-off-by: sZma5a --- .../docs-dev/user-guide/command-line-tool.md | 2 +- .../user-guide/configuration-reference.md | 2 +- .../en/docs-dev/user-guide/examples/_index.md | 2 +- .../{managing-controlplane => }/metrics.md | 26 ++++++++++++++++++- .../user-guide/terraform-provider-pipecd.md | 2 +- .../user-guide/command-line-tool.md | 2 +- .../user-guide/configuration-reference.md | 2 +- .../user-guide/examples/_index.md | 2 +- .../{managing-controlplane => }/metrics.md | 26 ++++++++++++++++++- .../user-guide/terraform-provider-pipecd.md | 2 +- 10 files changed, 58 insertions(+), 10 deletions(-) rename docs/content/en/docs-dev/user-guide/{managing-controlplane => }/metrics.md (69%) rename docs/content/en/docs-v0.44.x/user-guide/{managing-controlplane => }/metrics.md (69%) diff --git a/docs/content/en/docs-dev/user-guide/command-line-tool.md b/docs/content/en/docs-dev/user-guide/command-line-tool.md index 04d222392f..f2f2feca8e 100644 --- a/docs/content/en/docs-dev/user-guide/command-line-tool.md +++ b/docs/content/en/docs-dev/user-guide/command-line-tool.md @@ -1,7 +1,7 @@ --- title: "Command-line tool: pipectl" linkTitle: "Command-line tool: pipectl" -weight: 8 +weight: 9 description: > This page describes how to install and use pipectl to manage PipeCD's resources. --- diff --git a/docs/content/en/docs-dev/user-guide/configuration-reference.md b/docs/content/en/docs-dev/user-guide/configuration-reference.md index e239025f2f..32d011080f 100644 --- a/docs/content/en/docs-dev/user-guide/configuration-reference.md +++ b/docs/content/en/docs-dev/user-guide/configuration-reference.md @@ -1,7 +1,7 @@ --- title: "Configuration reference" linkTitle: "Configuration reference" -weight: 10 +weight: 11 description: > This page describes all configurable fields in the application configuration and analysis template. --- diff --git a/docs/content/en/docs-dev/user-guide/examples/_index.md b/docs/content/en/docs-dev/user-guide/examples/_index.md index 6a23bd430e..aa65fb850e 100755 --- a/docs/content/en/docs-dev/user-guide/examples/_index.md +++ b/docs/content/en/docs-dev/user-guide/examples/_index.md @@ -1,7 +1,7 @@ --- title: "Examples" linkTitle: "Examples" -weight: 11 +weight: 12 description: > Some examples of PipeCD in action! --- diff --git a/docs/content/en/docs-dev/user-guide/managing-controlplane/metrics.md b/docs/content/en/docs-dev/user-guide/metrics.md similarity index 69% rename from docs/content/en/docs-dev/user-guide/managing-controlplane/metrics.md rename to docs/content/en/docs-dev/user-guide/metrics.md index 34698f94f4..50485a4f57 100644 --- a/docs/content/en/docs-dev/user-guide/managing-controlplane/metrics.md +++ b/docs/content/en/docs-dev/user-guide/metrics.md @@ -1,7 +1,7 @@ --- title: "Metrics" linkTitle: "Metrics" -weight: 5 +weight: 8 description: > This page describes how to enable monitoring system for collecting PipeCD' metrics. --- @@ -86,3 +86,27 @@ And give it to the `helm install` command when [installing](../../../installatio ``` See [here](https://prometheus.io/docs/alerting/latest/configuration/) for more details on AlertManager's configuration. + +## Piped agent metrics + +| Metric | Type | Description | +| --- | --- | --- | +| `cloudprovider_kubernetes_tool_calls_total` | counter | Number of calls made to run the tool like kubectl, kustomize. | +| `deployment_status` | gauge | The current status of deployment. 1 for current status, 0 for others. | +| `livestatestore_kubernetes_api_requests_total` | counter | Number of requests sent to kubernetes api server. | +| `livestatestore_kubernetes_resource_events_total` | counter | Number of resource events received from kubernetes server. | +| `plan_preview_command_handled_total` | counter | Total number of plan-preview commands handled at piped. | +| `plan_preview_command_handling_seconds` | histogram | Histogram of handling seconds of plan-preview commands. | +| `plan_preview_command_received_total` | counter | Total number of plan-preview commands received at piped. | + +## Control plane metrics + +All Piped's metrics are sent to the control plane so that they are also available on the control plane's metrics server. + +| Metric | Type | Description | +| --- | --- | --- | +| `cache_get_operation_total` | counter | Number of cache get operation while processing. | +| `grpcapi_create_deployment_total` | counter | Number of successful CreateDeployment RPC with project label. | +| `http_request_duration_milliseconds` | histogram | Histogram of request latencies in milliseconds. | +| `http_requests_total` | counter | Total number of HTTP requests. | +| `insight_application_total` | gauge | Number of applications currently controlled by control plane. | diff --git a/docs/content/en/docs-dev/user-guide/terraform-provider-pipecd.md b/docs/content/en/docs-dev/user-guide/terraform-provider-pipecd.md index a0d0093eb2..8f1963e80a 100644 --- a/docs/content/en/docs-dev/user-guide/terraform-provider-pipecd.md +++ b/docs/content/en/docs-dev/user-guide/terraform-provider-pipecd.md @@ -1,7 +1,7 @@ --- title: "PipeCD Terraform provider" linkTitle: "PipeCD Terraform provider" -weight: 9 +weight: 10 description: > This page describes how to manage PipeCD resources with Terraform using terraform-provider-pipecd. --- diff --git a/docs/content/en/docs-v0.44.x/user-guide/command-line-tool.md b/docs/content/en/docs-v0.44.x/user-guide/command-line-tool.md index 04d222392f..f2f2feca8e 100644 --- a/docs/content/en/docs-v0.44.x/user-guide/command-line-tool.md +++ b/docs/content/en/docs-v0.44.x/user-guide/command-line-tool.md @@ -1,7 +1,7 @@ --- title: "Command-line tool: pipectl" linkTitle: "Command-line tool: pipectl" -weight: 8 +weight: 9 description: > This page describes how to install and use pipectl to manage PipeCD's resources. --- diff --git a/docs/content/en/docs-v0.44.x/user-guide/configuration-reference.md b/docs/content/en/docs-v0.44.x/user-guide/configuration-reference.md index 44e9a62f36..c5a38a421a 100644 --- a/docs/content/en/docs-v0.44.x/user-guide/configuration-reference.md +++ b/docs/content/en/docs-v0.44.x/user-guide/configuration-reference.md @@ -1,7 +1,7 @@ --- title: "Configuration reference" linkTitle: "Configuration reference" -weight: 10 +weight: 11 description: > This page describes all configurable fields in the application configuration and analysis template. --- diff --git a/docs/content/en/docs-v0.44.x/user-guide/examples/_index.md b/docs/content/en/docs-v0.44.x/user-guide/examples/_index.md index 6a23bd430e..aa65fb850e 100755 --- a/docs/content/en/docs-v0.44.x/user-guide/examples/_index.md +++ b/docs/content/en/docs-v0.44.x/user-guide/examples/_index.md @@ -1,7 +1,7 @@ --- title: "Examples" linkTitle: "Examples" -weight: 11 +weight: 12 description: > Some examples of PipeCD in action! --- diff --git a/docs/content/en/docs-v0.44.x/user-guide/managing-controlplane/metrics.md b/docs/content/en/docs-v0.44.x/user-guide/metrics.md similarity index 69% rename from docs/content/en/docs-v0.44.x/user-guide/managing-controlplane/metrics.md rename to docs/content/en/docs-v0.44.x/user-guide/metrics.md index 34698f94f4..50485a4f57 100644 --- a/docs/content/en/docs-v0.44.x/user-guide/managing-controlplane/metrics.md +++ b/docs/content/en/docs-v0.44.x/user-guide/metrics.md @@ -1,7 +1,7 @@ --- title: "Metrics" linkTitle: "Metrics" -weight: 5 +weight: 8 description: > This page describes how to enable monitoring system for collecting PipeCD' metrics. --- @@ -86,3 +86,27 @@ And give it to the `helm install` command when [installing](../../../installatio ``` See [here](https://prometheus.io/docs/alerting/latest/configuration/) for more details on AlertManager's configuration. + +## Piped agent metrics + +| Metric | Type | Description | +| --- | --- | --- | +| `cloudprovider_kubernetes_tool_calls_total` | counter | Number of calls made to run the tool like kubectl, kustomize. | +| `deployment_status` | gauge | The current status of deployment. 1 for current status, 0 for others. | +| `livestatestore_kubernetes_api_requests_total` | counter | Number of requests sent to kubernetes api server. | +| `livestatestore_kubernetes_resource_events_total` | counter | Number of resource events received from kubernetes server. | +| `plan_preview_command_handled_total` | counter | Total number of plan-preview commands handled at piped. | +| `plan_preview_command_handling_seconds` | histogram | Histogram of handling seconds of plan-preview commands. | +| `plan_preview_command_received_total` | counter | Total number of plan-preview commands received at piped. | + +## Control plane metrics + +All Piped's metrics are sent to the control plane so that they are also available on the control plane's metrics server. + +| Metric | Type | Description | +| --- | --- | --- | +| `cache_get_operation_total` | counter | Number of cache get operation while processing. | +| `grpcapi_create_deployment_total` | counter | Number of successful CreateDeployment RPC with project label. | +| `http_request_duration_milliseconds` | histogram | Histogram of request latencies in milliseconds. | +| `http_requests_total` | counter | Total number of HTTP requests. | +| `insight_application_total` | gauge | Number of applications currently controlled by control plane. | diff --git a/docs/content/en/docs-v0.44.x/user-guide/terraform-provider-pipecd.md b/docs/content/en/docs-v0.44.x/user-guide/terraform-provider-pipecd.md index a0d0093eb2..8f1963e80a 100644 --- a/docs/content/en/docs-v0.44.x/user-guide/terraform-provider-pipecd.md +++ b/docs/content/en/docs-v0.44.x/user-guide/terraform-provider-pipecd.md @@ -1,7 +1,7 @@ --- title: "PipeCD Terraform provider" linkTitle: "PipeCD Terraform provider" -weight: 9 +weight: 10 description: > This page describes how to manage PipeCD resources with Terraform using terraform-provider-pipecd. ---