Skip to content

Commit

Permalink
grafana: ignore empty values
Browse files Browse the repository at this point in the history
Ignore empty values so the aggregate looks better.

Signed-off-by: Leonardo Graboski Veiga <[email protected]>
  • Loading branch information
leograba committed Jan 20, 2024
1 parent 173d63e commit db275a7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions TorizonOSBuildStatusGrafana/grafana-config/dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@
"type": "influxdb",
"uid": "influxdb_jenkins"
},
"query": "from(bucket: \"jenkinsdatabucket\")\n |> range(start: -1h)\n |> filter(fn: (r) => r[\"_measurement\"] == \"jenkinsbuild\")\n |> last()\n |> pivot(rowKey:[\"_time\"], columnKey: [\"_field\"], valueColumn: \"_value\")\n |> drop(columns: [\"_time\", \"_start\", \"_stop\"])",
"query": "from(bucket: \"jenkinsdatabucket\")\n |> range(start: -1h)\n |> filter(fn: (r) => r[\"_measurement\"] == \"jenkinsbuild\" and r[\"_value\"] != \"\")\n |> last()\n |> pivot(rowKey:[\"_time\"], columnKey: [\"_field\"], valueColumn: \"_value\")\n |> drop(columns: [\"_time\", \"_start\", \"_stop\"])",
"refId": "A"
}
],
Expand Down Expand Up @@ -221,7 +221,7 @@
"type": "influxdb",
"uid": "influxdb_jenkins"
},
"query": "from(bucket: \"jenkinsdatabucket\")\n |> range(start: -30d)\n |> filter(fn: (r) => r[\"_measurement\"] == \"jenkinsbuild\")\n |> aggregateWindow(every: 1d, fn: first)\n |> map(fn: (r) => ({_time: r._time, _field: r._field, _value: r._value}))\n",
"query": "from(bucket: \"jenkinsdatabucket\")\n |> range(start: -30d)\n |> filter(fn: (r) => r[\"_measurement\"] == \"jenkinsbuild\" and r[\"_value\"] != \"\")\n |> aggregateWindow(every: 1d, fn: first)\n |> map(fn: (r) => ({_time: r._time, _field: r._field, _value: r._value}))\n",
"refId": "A"
}
],
Expand Down

0 comments on commit db275a7

Please sign in to comment.