http://<host:<http-port/_status/varshttp://<host:<http-port/metrics: an enhanced endpoint with additional static labels
In addition to using the exported time-series data to monitor a cluster through an external system, you can write alerting rules to ensure prompt notification of critical events or issues requiring intervention or investigation. Refer to for more details.
_status/vars
To access the _status/vars Prometheus endpoint of a cluster running on localhost:8080:
sql_*_count*.
metrics
This feature is in and subject to change. To share feedback and/or issues, contact Support.
metrics Prometheus endpoint is commonly used and is the default in Prometheus configurations.
To access the metrics Prometheus endpoint of a cluster running on localhost:8080:
sql_count, with static labels for query_type (with values of insert, select, update, and delete) and query_internal (with value of true).
Static labels
One common use of static labels is to allow segmentation of a metric across various facets for later querying and aggregation. For example, rather than emitting separate metrics forINSERT, SELECT, UPDATE, and DELETE statements, the single metric sql_count uses the query_type label to distinguish between these operations. This enables operators to easily aggregate across query types (e.g., summing a metric for all SQL operations) or filter for a specific type using the appropriate value for the query_type label.
The following tables contrast unlabeled metrics from the _status/vars endpoint with their labeled counterparts from the metrics endpoint:
At metrics query time, labels provide a more seamless user experience:
In other cases, label values can represent distinct categories not intended for aggregation. For example, certificate expiration metrics differ only by the specific certificate type they represent. Operators are unlikely to sum or average these, but may still want to display them side by side on a dashboard for visibility.
In this case, a single metric name like
security_certificate_expiration is reused, with the certificate type expressed as a label. The metrics endpoint returns output similar to the following:

