Reading and visualizing metrics with Grafana
Written by
Updated at March 28, 2024
Yandex Managed Service for Prometheus® supports the Prometheus data source
Connecting a data source
- In the management console
, select the folder where data is stored. - Create a service account with the
monitoring.viewer
role for the selected folder. - Create an API key for the service account.
- Open the homepage of your Grafana installation.
- In the main menu, select Configuration → Data Sources.
- Click Add data source.
- Under Time series databases, select Prometheus.
- In the Name field, enter the data source name.
- In the URL field, the HTTP section, specify the previously obtained endpoint.
- Under Custom HTTP headers, click Add Header and add a header for authorization. In the Header field, enter
Authorization
; in the Value field, enterBearer <API_key>
. - Click Save & test. You should see a message saying
The data source is working
.
Current limitations
The Prometheus HTTP API
/api/v1/query
/api/v1/query_range
/api/v1/labels
/api/v1/<label_name>/values
/api/v1/series
The following limitations apply:
- The
timeout
parameter is not supported and is ignored. - The
start
andend
parameters are not supported and are ignored for/api/v1/labels
,/api/v1/<label_name>/values
, and/api/v1/series
requests. - The maximum number of selectors that you can provide as the
match[]
parameter is 8. - The maximum number of time series that you can get metadata for using
/api/v1/series
requests is 10,000. - The maximum number of time series that can be read per
/api/v1/query
or/api/v1/query_range
is 10,000. - The
--query.lookback-delta
parameter value is5m
.
© 2024 Linux Foundation. All rights reserved. The Linux Foundation owns and uses registered trademarks. For a list of Linux Foundation trademarks, see Trademark Usage