ACK clusters integrate with Managed Service for Prometheus and Managed Service for Grafana, so you don't need to build your own monitoring infrastructure. After deploying applications in Knative, import monitoring data to Managed Service for Prometheus and view real-time metrics in Grafana.
Prerequisites
Before you begin, ensure that you have:
Knative deployed in your cluster. For more information, see Deploy Knative.
Billing
Knative monitoring metrics ingested to Managed Service for Prometheus are treated as custom metrics, and fees apply. Costs vary based on cluster size and the number of applications. Review the Billing overview before enabling this feature. To track ongoing resource usage, see View resource usage.
Activate Managed Service for Prometheus
Log on to the ACK console. In the left navigation pane, click Clusters.
On the Clusters page, click the name of your cluster. In the left navigation pane, choose Applications > Knative.
On the Knative Components page, click the Monitoring Dashboards tab and follow the on-screen instructions to enable Prometheus dashboards.
View the Knative dashboard
After activating Managed Service for Prometheus, view monitoring data on the Monitoring Dashboards tab.
| Category | Description |
|---|---|
| Request data | In the Overview (average over the selected time range) section, view the following data:
|
| Response latency data | In the Response Time section, view the P50, P90, P95, and P99 response latency of Knative. |
| Request concurrency data | In the Autoscaler section, view detailed request concurrency information for Knative. |
| Activator | In the Activator section, view the following Knative activator metrics:
|
| Resource usage | In the Resource Usages section, view CPU and memory usage of Knative resources. |
View Knative service discovery metrics
Use the Metrics Explorer in the ARMS console to view and validate Knative service metrics by selecting predefined metrics or writing custom PromQL queries. For detailed steps, see Metric exploration.
Log on to the ARMS console. In the left navigation pane, click Integration Management.
On the Integration Management page, select a region. Click the Integrated Environments > Container Service tab, then click Knative in the Integrated Addons column.
On the page that appears, click the Metrics Explorer tab.
When the number of pods for a Knative application scales to zero, Managed Service for Prometheus cannot collect metrics such as request concurrency and requests per second. These metrics are only available after you access the pods of the Knative application.
When the pod count is not zero, the metrics are available directly without accessing pods.
The following table lists the key Knative service discovery metrics.
| Metric | Description |
|---|---|
queue_average_concurrent_requests | The number of concurrent requests sent to a pod. |
queue_requests_per_second | The number of requests sent to a pod per second. |
revision_request_latencies | The response latency of revision requests. |
revision_request_count | The number of revision requests. |
What's next
To set up log collection, monitoring, and alerting for Knative using Simple Log Service (SLS), see Enable SLS on Knative and Configure alerting for Knative Services.