Skip to content

Commit

Permalink
Replacing/removing dropped features in PromQL (#33)
Browse files Browse the repository at this point in the history
* replace removed count_scalar(...) function with equivalent scalar(count(...))

* keep_common aggregation modifier has been removed upstream
  • Loading branch information
Igor Živković authored and Jonne Nauha committed Jul 23, 2018
1 parent 7c2b385 commit 8d7b281
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions dashboards/jonnenauha/dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,7 @@
"tableColumn": "",
"targets": [
{
"expr": "count_scalar(varnish_backend_up{instance=~\"^($varnish_instance).*\"} == 1)",
"expr": "scalar(count(varnish_backend_up{instance=~\"^($varnish_instance).*\"} == 1))",
"format": "time_series",
"interval": "1m",
"intervalFactor": 1,
Expand Down Expand Up @@ -691,7 +691,7 @@
"tableColumn": "",
"targets": [
{
"expr": "count_scalar(varnish_backend_up{instance=~\"^($varnish_instance).*\"} == 0)",
"expr": "scalar(count(varnish_backend_up{instance=~\"^($varnish_instance).*\"} == 0))",
"format": "time_series",
"interval": "1m",
"intervalFactor": 1,
Expand Down Expand Up @@ -1186,7 +1186,7 @@
"step": 60
},
{
"expr": "sum(irate(varnish_backend_beresp_hdrbytes{instance=~\"^($varnish_instance).*\"}[5m]) + irate(varnish_backend_beresp_bodybytes{instance=~\"^($varnish_instance).*\"}[5m])) keep_common",
"expr": "sum(irate(varnish_backend_beresp_hdrbytes{instance=~\"^($varnish_instance).*\"}[5m]) + irate(varnish_backend_beresp_bodybytes{instance=~\"^($varnish_instance).*\"}[5m]))",
"format": "time_series",
"hide": false,
"interval": "",
Expand All @@ -1197,7 +1197,7 @@
"step": 60
},
{
"expr": "sum(irate(varnish_backend_beresp_hdrbytes{instance=~\"^($varnish_instance).*\"}[5m]) + irate(varnish_backend_beresp_bodybytes{instance=~\"^($varnish_instance).*\"}[5m])) by (backend) keep_common",
"expr": "sum(irate(varnish_backend_beresp_hdrbytes{instance=~\"^($varnish_instance).*\"}[5m]) + irate(varnish_backend_beresp_bodybytes{instance=~\"^($varnish_instance).*\"}[5m])) by (backend)",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "backend {{ backend }}",
Expand Down Expand Up @@ -1442,4 +1442,4 @@
"timezone": "browser",
"title": "Varnish",
"version": 26
}
}

0 comments on commit 8d7b281

Please sign in to comment.