Skip to content

Commit

Permalink
Fix variable values
Browse files Browse the repository at this point in the history
http_request_duration_seconds was a prometheus summary. We switched to
prometheus histograms in alphagov/govuk_app_config#318

The histogram metric is called http_request_duration_seconds_bucket
(note the extra `_bucket`). Now that most of the apps don't use the
http_request_duration_seconds metric, it's missing most of the app
labels, making it the wrong place to query to get the list of apps.

Instead, the http_requests_total metric has everything we need.

I've also removed the "quantile" variable, as we're no longer using the
summary metric which includes quantile as a label.
  • Loading branch information
richardTowers committed Oct 4, 2023
1 parent 267b81f commit c6276ff
Showing 1 changed file with 2 additions and 33 deletions.
35 changes: 2 additions & 33 deletions charts/monitoring-config/dashboards/app-requests.json
Original file line number Diff line number Diff line change
Expand Up @@ -603,14 +603,14 @@
"type": "prometheus",
"uid": "prometheus"
},
"definition": "label_values(http_request_duration_seconds{namespace=\"${namespace}\"}, job)",
"definition": "label_values(http_requests_total{namespace=\"${namespace}\"},job)",
"hide": 0,
"includeAll": true,
"multi": true,
"name": "app",
"options": [],
"query": {
"query": "label_values(http_request_duration_seconds{namespace=\"${namespace}\"}, job)",
"query": "label_values(http_requests_total{namespace=\"${namespace}\"},job)",
"refId": "StandardVariableQuery"
},
"refresh": 2,
Expand All @@ -619,37 +619,6 @@
"sort": 1,
"type": "query"
},
{
"current": {
"selected": true,
"text": [
"All"
],
"value": [
"$__all"
]
},
"datasource": {
"type": "prometheus",
"uid": "prometheus"
},
"definition": "label_values(http_request_duration_seconds{namespace=\"${namespace}\"}, quantile)",
"hide": 0,
"includeAll": true,
"label": "quantile",
"multi": true,
"name": "quantile",
"options": [],
"query": {
"query": "label_values(http_request_duration_seconds{namespace=\"${namespace}\"}, quantile)",
"refId": "StandardVariableQuery"
},
"refresh": 2,
"regex": "",
"skipUrlSync": false,
"sort": 4,
"type": "query"
},
{
"allValue": "",
"current": {
Expand Down

0 comments on commit c6276ff

Please sign in to comment.