Reputation: 90
I want to fliter out metrics starting with particular word in prometheus and it should display all the occurrence
Upvotes: 1
Views: 4819
Reputation: 22361
Use the following query:
{__name__=~"STRING.+"}
If you want to search using the REST API execute:
curl --globoff --request GET "http://PROMETHEUS-SERVER/api/v1/query?query={__name__=~'prom.%2B'}"
Upvotes: 1