Parse Error preventing environment specific metric from working
Summary
Unable to create custom metric in Prometheus Integration
Steps to reproduce
Following the instructions provided here: https://ops.gitlab.net/help/user/project/integrations/prometheus#adding-additional-metrics-premium
I'm using the following query: sum(irate(registry_http_requests_total{environment=%{ci_environment_slug}}[1m])) by (handler, code)
The response during validation is hidden from view. It can be found in Dev Tools, however:
{
"success": true,
"last_update": "2019-09-25T17:17:02.147Z",
"query": {
"valid": false,
"error": "parse error at char 52: unexpected character inside braces: '%'"
}
}
What is the expected correct behavior?
When following the documentation, I would've expected a working query.
Relevant logs and/or screenshots
Output of checks
GitLab.com