diff --git a/grafana/postgres/v12/biggest-relations.json b/grafana/postgres/v12/biggest-relations.json index ed8285fa1..aaba91796 100644 --- a/grafana/postgres/v12/biggest-relations.json +++ b/grafana/postgres/v12/biggest-relations.json @@ -25,10 +25,8 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, - "iteration": 1703497578925, + "id": 16, "links": [], - "liveNow": false, "panels": [ { "datasource": { @@ -48,8 +46,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" } ] }, @@ -64,13 +61,13 @@ "y": 0 }, "id": 3, - "links": [], "maxDataPoints": 100, "options": { "sizeField": "total_relation_size_b", "textField": "table_name", "tiling": "treemapSquarify" }, + "pluginVersion": "2.1.1", "targets": [ { "alias": "$tag_table_name", @@ -146,8 +143,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" } ] }, @@ -162,13 +158,13 @@ "y": 10 }, "id": 1, - "links": [], "maxDataPoints": 100, "options": { "sizeField": "table_size_b", "textField": "table_name", "tiling": "treemapSquarify" }, + "pluginVersion": "2.1.1", "targets": [ { "alias": "$tag_table_name", @@ -257,8 +253,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" } ] }, @@ -273,13 +268,13 @@ "y": 22 }, "id": 2, - "links": [], "maxDataPoints": 100, "options": { "sizeField": "index_size_b", "textField": "index_full_name", "tiling": "treemapSquarify" }, + "pluginVersion": "2.1.1", "targets": [ { "alias": "$tag_index_name", @@ -338,11 +333,10 @@ "type": "marcusolsson-treemap-panel" }, { - "datasource": { - "type": "postgres" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, - "editable": true, - "error": false, "gridPos": { "h": 7, "w": 24, @@ -350,44 +344,40 @@ "y": 29 }, "id": 4, - "links": [], "options": { "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, "pluginVersion": "8.5.20", + "title": "", "transparent": true, "type": "text" } ], + "preload": false, "refresh": "1m", - "schemaVersion": 36, - "style": "dark", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "current": {}, + "current": { + "text": "demo", + "value": "demo" + }, "datasource": { "type": "postgres" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'table_stats' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -395,34 +385,9 @@ "from": "now-3h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Biggest relations treemap", "uid": "biggest-relations", - "version": 1, - "weekStart": "" + "version": 6 } \ No newline at end of file diff --git a/grafana/postgres/v12/change-events.json b/grafana/postgres/v12/change-events.json index f9c0accc8..058900ec8 100644 --- a/grafana/postgres/v12/change-events.json +++ b/grafana/postgres/v12/change-events.json @@ -19,6 +19,7 @@ "uid": "pgwatch-metrics" }, "enable": true, + "hide": false, "iconColor": "rgba(255, 96, 96, 1)", "limit": 100, "name": "changes summary", @@ -33,6 +34,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 5, "links": [], "panels": [ { @@ -53,6 +55,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -84,8 +87,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -163,11 +165,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "CPU load", @@ -297,6 +300,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -308,8 +312,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -356,7 +359,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -433,6 +436,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -444,8 +448,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -492,7 +495,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -569,6 +572,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -580,8 +584,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -628,7 +631,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -705,6 +708,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -716,8 +720,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -764,7 +767,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -841,6 +844,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -852,8 +856,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -900,7 +903,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -977,6 +980,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -988,8 +992,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1036,7 +1039,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1112,6 +1115,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -1124,8 +1128,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1176,7 +1179,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1221,8 +1224,9 @@ "type": "table" } ], - "refresh": false, - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1230,30 +1234,21 @@ "list": [ { "current": { - "isNone": true, - "selected": false, - "text": "None", - "value": "" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics ORDER BY 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -1261,34 +1256,9 @@ "from": "now-12h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Change events", "uid": "change-events", - "version": 1, - "weekStart": "" + "version": 11 } \ No newline at end of file diff --git a/grafana/postgres/v12/checkpointer-bgwriter-stats.json b/grafana/postgres/v12/checkpointer-bgwriter-stats.json index db17fb30a..bb349d62f 100644 --- a/grafana/postgres/v12/checkpointer-bgwriter-stats.json +++ b/grafana/postgres/v12/checkpointer-bgwriter-stats.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 33, "links": [], "panels": [ { @@ -37,6 +38,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "points", "fillOpacity": 10, "gradientMode": "none", @@ -69,8 +71,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -115,11 +116,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "checkpoints_timed", @@ -208,6 +210,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -239,8 +242,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -269,11 +271,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "checkpoint_write_time", @@ -362,6 +365,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -394,8 +398,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -425,11 +428,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "buffers_checkpoint", @@ -519,6 +523,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -550,8 +555,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -581,11 +585,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "blk_read_time (backend)", @@ -675,6 +680,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -707,8 +713,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -727,7 +732,6 @@ "y": 20 }, "id": 7, - "interval": "", "options": { "legend": { "calcs": [ @@ -738,11 +742,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "heap_blks_read", @@ -815,12 +820,10 @@ "type": "timeseries" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, - "editable": true, - "error": false, "gridPos": { "h": 7, "w": 12, @@ -835,23 +838,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -859,40 +856,30 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'bgwriter' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "1h", "value": "1h" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -968,7 +955,6 @@ ], "query": "1s,1m,5m,10m,15m,30m,1h,3h,6h,12h,1d,7d,14d,30d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -977,34 +963,9 @@ "from": "now-24h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Checkpointer / Bgwriter / Block IO Stats", "uid": "checkpointer-bgwriter-stats", - "version": 3, - "weekStart": "" + "version": 7 } \ No newline at end of file diff --git a/grafana/postgres/v12/global-health.json b/grafana/postgres/v12/global-health.json index e9b15444e..342e848a5 100644 --- a/grafana/postgres/v12/global-health.json +++ b/grafana/postgres/v12/global-health.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 2, "links": [], "panels": [ { @@ -38,8 +39,7 @@ "mode": "absolute", "steps": [ { - "color": "dark-red", - "value": null + "color": "dark-red" }, { "color": "dark-green", @@ -72,7 +72,7 @@ "showThresholdMarkers": true, "sizing": "auto" }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -147,8 +147,7 @@ "mode": "absolute", "steps": [ { - "color": "dark-red", - "value": null + "color": "dark-red" }, { "color": "dark-orange", @@ -185,7 +184,7 @@ "showThresholdMarkers": true, "sizing": "auto" }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -265,8 +264,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -301,8 +299,7 @@ "mode": "absolute", "steps": [ { - "color": "#FA6400", - "value": null + "color": "#FA6400" }, { "color": "#E02F44", @@ -382,7 +379,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -450,8 +447,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -490,8 +486,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -557,7 +552,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -624,8 +619,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -664,8 +658,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -730,7 +723,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -797,8 +790,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -862,8 +854,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -899,7 +890,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -966,8 +957,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1031,8 +1021,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1068,7 +1057,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1135,8 +1124,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1171,8 +1159,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1241,7 +1228,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1308,8 +1295,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1344,8 +1330,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1410,7 +1395,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1477,8 +1462,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1517,8 +1501,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1583,7 +1566,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1650,8 +1633,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1719,8 +1701,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1756,7 +1737,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1823,8 +1804,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1903,7 +1883,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1948,9 +1928,9 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 8, @@ -1966,24 +1946,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, - "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "pluginVersion": "12.0.0", + "title": "", "transparent": true, "type": "text" } ], + "preload": false, "refresh": "1m", - "schemaVersion": 39, + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1991,13 +1964,10 @@ "list": [ { "current": { - "selected": false, "text": "3", "value": "3" }, - "hide": 0, "includeAll": false, - "multi": false, "name": "top_limit", "options": [ { @@ -2022,7 +1992,6 @@ } ], "query": "1,3,5,10", - "skipUrlSync": false, "type": "custom" } ] @@ -2031,23 +2000,9 @@ "from": "now-5m", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Global Health", "uid": "global-health", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/health-check.json b/grafana/postgres/v12/health-check.json index 52e97c01c..a224da846 100644 --- a/grafana/postgres/v12/health-check.json +++ b/grafana/postgres/v12/health-check.json @@ -3,7 +3,10 @@ "list": [ { "builtIn": 1, - "datasource": "-- Grafana --", + "datasource": { + "type": "datasource", + "uid": "grafana" + }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", @@ -14,30 +17,57 @@ }, "description": "Current and avg. KPI-s. Expects 'get_load_average' and 'backends' helpers to be installed on the monitored DB.", "editable": true, - "gnetId": null, + "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, + "id": 1, "links": [], "panels": [ { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "PRIMARY - accepting writes, REPLICA - read-only", - "format": "none", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "1": { + "text": "REPLICA" + } + }, + "type": "value" + }, + { + "options": { + "0": { + "text": "PRIMARY" + } + }, + "type": "value" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 2 + } + ] + }, + "unit": "none" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -47,43 +77,31 @@ }, "hideTimeOverride": true, "id": 28, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -133,44 +151,49 @@ ] } ], - "thresholds": "1,2", "timeFrom": "$online_interval", "title": "Instance state", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "REPLICA", - "value": "1" - }, - { - "op": "=", - "text": "PRIMARY", - "value": "0" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#d44a3a", - "rgba(237, 129, 40, 0.89)", - "#299c46" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Time from last Postgres process restart. < 5m Error, < 30m Warn thresholds by default", - "format": "dtdurations", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#d44a3a" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 300 + }, + { + "color": "#299c46", + "value": 1800 + } + ] + }, + "unit": "dtdurations" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -180,43 +203,31 @@ }, "hideTimeOverride": true, "id": 18, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -272,39 +283,49 @@ ] } ], - "thresholds": "300, 1800", "timeFrom": "$online_interval", "title": "Instance uptime", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#C4162A", - "#FA6400", - "#299c46" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "\"SHOW server_version_num;\"\n110005 => 11.5", - "format": "none", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#C4162A" + }, + { + "color": "#FA6400", + "value": 90400 + }, + { + "color": "#299c46", + "value": 90600 + } + ] + }, + "unit": "none" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -314,7 +335,6 @@ }, "hideTimeOverride": true, "id": 44, - "interval": null, "links": [ { "targetBlank": true, @@ -322,41 +342,31 @@ "url": "/d/postgres-version-overview?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -406,39 +416,49 @@ ] } ], - "thresholds": "90400,90600", "timeFrom": "6h", "title": "PG version num.", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Longest query duration during last $online_interval", - "format": "dtdurations", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 30 + }, + { + "color": "#d44a3a", + "value": 300 + } + ] + }, + "unit": "dtdurations" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -448,43 +468,31 @@ }, "hideTimeOverride": true, "id": 32, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -540,39 +548,49 @@ ] } ], - "thresholds": "30,300", "timeFrom": "$online_interval", "title": "Longest query runtime", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "rgba(237, 129, 40, 0.89)", - "#299c46", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Connected sessions, including Postgres internal processes like Autovacuum. < 1 Warn / > 300 Error thresholds by default", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "rgba(237, 129, 40, 0.89)" + }, + { + "color": "#299c46", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 300 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -582,7 +600,6 @@ }, "hideTimeOverride": true, "id": 15, - "interval": null, "links": [ { "targetBlank": true, @@ -590,41 +607,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=11&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -680,39 +687,49 @@ ] } ], - "thresholds": "1,300", "timeFrom": "$online_interval", "title": "Active connections", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "#FA6400", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "\"max_connections\" configuration setting. Changing requires re-start. 500/1000 Warn / Error thresholds by default", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "#FA6400", + "value": 500 + }, + { + "color": "#d44a3a", + "value": 1000 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -722,7 +739,6 @@ }, "hideTimeOverride": true, "id": 45, - "interval": null, "links": [ { "targetBlank": true, @@ -730,41 +746,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=11&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -820,39 +826,49 @@ ] } ], - "thresholds": "500,1000", "timeFrom": "6h", "title": "Max. connections", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Max number of queries waiting on resources locked by other sessions. 1 Warn / 5 Err thresholds by default", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 5 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -862,7 +878,6 @@ }, "hideTimeOverride": true, "id": 34, - "interval": null, "links": [ { "targetBlank": true, @@ -870,41 +885,31 @@ "url": "/d/lock-details?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -960,39 +965,52 @@ ] } ], - "thresholds": "1,5", "timeFrom": "$online_interval", "title": "Blocked sessions", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#d44a3a", - "rgba(237, 129, 40, 0.89)", - "#299c46" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Shared Buffers is the Postgres -managed file cache and 90%+ is what you normally want to see for best performance.", - "format": "percent", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "color": "#d44a3a", + "text": "0" + } + }, + "type": "special" + } + ], + "max": 100, + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#d44a3a" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 50 + }, + { + "color": "#299c46", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1000,9 +1018,7 @@ "x": 18, "y": 2 }, - "hideTimeOverride": true, "id": 21, - "interval": null, "links": [ { "targetBlank": true, @@ -1010,41 +1026,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=8&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1100,39 +1106,50 @@ ] } ], - "thresholds": "50,80", - "timeFrom": null, "title": "Shared Buffers hit pct.", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "0", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "0.5% Warn / 1% Error thresholds by default", - "format": "percent", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "max": 100, + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 0.5 + }, + { + "color": "#d44a3a", + "value": 1 + } + ] + }, + "unit": "percent" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1140,9 +1157,7 @@ "x": 0, "y": 4 }, - "hideTimeOverride": true, "id": 13, - "interval": null, "links": [ { "targetBlank": true, @@ -1150,41 +1165,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=8&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1234,39 +1239,48 @@ ] } ], - "thresholds": "0.5, 1", - "timeFrom": null, "title": "TX rollback pct. (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#d44a3a", - "rgba(237, 129, 40, 0.89)", - "#299c46" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Transactions per Second. Last $online_interval average. <0.1 % Error / < 1.0 Warn thresholds by default", - "format": "short", - "gauge": { - "maxValue": null, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": false + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#d44a3a" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 0.1 + }, + { + "color": "#299c46", + "value": 1 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1274,9 +1288,7 @@ "x": 6, "y": 4 }, - "hideTimeOverride": true, "id": 7, - "interval": null, "links": [ { "targetBlank": true, @@ -1284,41 +1296,31 @@ "url": "/d/db-overview-developer?$__all_variables&viewPanel=15&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1368,39 +1370,48 @@ ] } ], - "thresholds": "0.1,1", - "timeFrom": null, "title": "TPS (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#d44a3a", - "rgba(237, 129, 40, 0.89)", - "#299c46" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Queries per Second based on \"pg_stat_statements\" extension info. Last $online_interval avg. < 0.1 Error / < 1 Warning thresholds by default", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#d44a3a" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 0.1 + }, + { + "color": "#299c46", + "value": 1 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1408,9 +1419,7 @@ "x": 12, "y": 4 }, - "hideTimeOverride": true, "id": 16, - "interval": null, "links": [ { "targetBlank": true, @@ -1418,41 +1427,31 @@ "url": "/d/db-overview-developer?$__all_variables&viewPanel=15&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1502,39 +1501,48 @@ ] } ], - "thresholds": "0.1, 1", - "timeFrom": null, "title": "QPS (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Transactions opened but where no queries are being executed.", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 5 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1544,7 +1552,6 @@ }, "hideTimeOverride": true, "id": 33, - "interval": null, "links": [ { "targetBlank": true, @@ -1552,41 +1559,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=11&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1642,39 +1639,45 @@ ] } ], - "thresholds": "1,5", "timeFrom": "$online_interval", "title": "\"Idle in TX\" count", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": false, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Size for selected DB only", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1682,9 +1685,7 @@ "x": 0, "y": 6 }, - "hideTimeOverride": true, "id": 25, - "interval": null, "links": [ { "targetBlank": true, @@ -1692,41 +1693,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=10&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1776,39 +1767,44 @@ ] } ], - "thresholds": "", - "timeFrom": null, "title": "DB size (last)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": false, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1816,9 +1812,7 @@ "x": 6, "y": 6 }, - "hideTimeOverride": true, "id": 23, - "interval": null, "links": [ { "targetBlank": true, @@ -1826,41 +1820,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=10&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1910,39 +1894,49 @@ ] } ], - "thresholds": "", - "timeFrom": null, "title": "DB size change (diff.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#d44a3a", - "rgba(237, 129, 40, 0.89)", - "#299c46" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Assumes get_psutil_disk wrapper being installed. 10/50GB Warn/Error thresholds by default", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "color": "#d44a3a", + "text": "0" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#d44a3a" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 10000000 + }, + { + "color": "#299c46", + "value": 50000000 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -1950,9 +1944,7 @@ "x": 12, "y": 6 }, - "hideTimeOverride": true, "id": 24, - "interval": null, "links": [ { "targetBlank": true, @@ -1960,41 +1952,31 @@ "url": "/d/system-stats?$__all_variables&viewPanel=8&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2050,39 +2032,48 @@ ] } ], - "thresholds": "10000000,50000000", - "timeFrom": null, "title": "DATADIR disk space left", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "0", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Last $online_interval avg. based on \"pg_stat_statements\" info. > 0.5s Warning / > 5s Error thresholds by default", - "format": "ms", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 500 + }, + { + "color": "#d44a3a", + "value": 5000 + } + ] + }, + "unit": "ms" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -2090,9 +2081,7 @@ "x": 18, "y": 6 }, - "hideTimeOverride": true, "id": 17, - "interval": null, "links": [ { "targetBlank": true, @@ -2100,41 +2089,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=12&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2184,39 +2163,48 @@ ] } ], - "thresholds": "500, 5000", - "timeFrom": null, "title": "Query runtime (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Server configuration changes. >1 Warn thresholds by default", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "color": "#299c46", + "text": "0" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a" + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -2224,9 +2212,7 @@ "x": 0, "y": 8 }, - "hideTimeOverride": true, "id": 22, - "interval": null, "links": [ { "targetBlank": true, @@ -2234,41 +2220,31 @@ "url": "/d/change-events?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2324,39 +2300,48 @@ ] } ], - "thresholds": "1", - "timeFrom": null, "title": "Config change events", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "0", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Number of DDL changes i.e. new or changed tables, columns, functions etc. >1 Warn thresholds by default", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "color": "#299c46", + "text": "0" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a" + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -2364,9 +2349,7 @@ "x": 6, "y": 8 }, - "hideTimeOverride": true, "id": 20, - "interval": null, "links": [ { "targetBlank": true, @@ -2374,41 +2357,31 @@ "url": "/d/change-events?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2464,39 +2437,64 @@ ] } ], - "thresholds": "1", - "timeFrom": null, "title": "Table changes", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "0", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Based on pg_stat_archiver. N/A when archiving is not enabled.", - "format": "none", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + }, + { + "options": { + "0": { + "text": "OK" + } + }, + "type": "value" + }, + { + "options": { + "1": { + "text": "FAILING" + } + }, + "type": "value" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 2 + } + ] + }, + "unit": "none" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -2506,43 +2504,31 @@ }, "hideTimeOverride": true, "id": 19, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2598,49 +2584,49 @@ ] } ], - "thresholds": "1,2", "timeFrom": "$online_interval", "title": "WAL archiving status", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - }, - { - "op": "=", - "text": "OK", - "value": "0" - }, - { - "op": "=", - "text": "FAILING", - "value": "1" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Transaction Log Folder size. Assumes get_wal_size helper being installed. 1/10 GB Warn / 50 Error thresholds by default", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1000000000 + }, + { + "color": "#d44a3a", + "value": 10000000000 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -2648,9 +2634,7 @@ "x": 18, "y": 8 }, - "hideTimeOverride": true, "id": 14, - "interval": null, "links": [ { "targetBlank": true, @@ -2658,41 +2642,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=10&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2742,39 +2716,38 @@ ] } ], - "thresholds": "1000000000,10000000000", - "timeFrom": null, "title": "WAL folder size", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Invalid indexes should be dropped as they're updated on DML operations but cannot be used for speeding up queries. In case multiple indexes of same structure Postgres will use the smallest so the others can be dropped. 'N/A' displayed both when no duplicate indexes or no metrics data for index_stats.", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 2 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -2782,9 +2755,7 @@ "x": 0, "y": 10 }, - "hideTimeOverride": true, "id": 29, - "interval": null, "links": [ { "targetBlank": true, @@ -2792,41 +2763,31 @@ "url": "/d/index-overview" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2876,33 +2837,48 @@ ] } ], - "thresholds": "1,2", - "timeFrom": null, "title": "Invalid / duplicate indexes", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "i.e. AUTOVACUUM disabled globally or per table.", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 10 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -2910,45 +2886,32 @@ "x": 6, "y": 10 }, - "hideTimeOverride": true, "id": 30, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -2998,39 +2961,48 @@ ] } ], - "thresholds": "1,10", - "timeFrom": null, "title": "Autovacuum issues", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Checkpoints should normally be performed by the background \"Checkpointer\" process. If seeing high numbers then adjusting server configuration is recommended.", - "format": "none", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 2 + } + ] + }, + "unit": "none" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -3038,9 +3010,7 @@ "x": 12, "y": 10 }, - "hideTimeOverride": true, "id": 26, - "interval": null, "links": [ { "targetBlank": true, @@ -3048,41 +3018,31 @@ "url": "/d/checkpointer-bgwriter-stats?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "diff" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -3138,39 +3098,44 @@ ] } ], - "thresholds": "1,2", - "timeFrom": null, "title": "Checkpoints requested", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "diff" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": false, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Estimated extra space held by tables (excluding indexes) that would disappear after \"compacting\".", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -3180,43 +3145,31 @@ }, "hideTimeOverride": true, "id": 27, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -3266,39 +3219,49 @@ ] } ], - "thresholds": "", "timeFrom": "1d", "title": "Approx. table bloat", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Transaction logs generation velocity.", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 1000000 + }, + { + "color": "#d44a3a", + "value": 16000000 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -3306,9 +3269,7 @@ "x": 0, "y": 12 }, - "hideTimeOverride": true, "id": 36, - "interval": null, "links": [ { "targetBlank": true, @@ -3316,41 +3277,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=10&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -3412,39 +3363,48 @@ ] } ], - "thresholds": "1000000,16000000", - "timeFrom": null, "title": "WAL per second (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Postgres writes temporary files to disk when sorting / grouping big amounts of data that doesn't fit into \"work_mem\". 10/100 MB Warn / Error by default", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 10000000 + }, + { + "color": "#d44a3a", + "value": 100000000 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -3452,9 +3412,7 @@ "x": 6, "y": 12 }, - "hideTimeOverride": true, "id": 37, - "interval": null, "links": [ { "targetBlank": true, @@ -3462,41 +3420,31 @@ "url": "/d/db-overview?$__all_variables&viewPanel=19&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -3558,39 +3506,48 @@ ] } ], - "thresholds": "10000000,100000000", - "timeFrom": null, "title": "Temp. bytes per second (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Long running AUTOVACUUM processes can hint at workload or configuration problems", - "format": "dtdurations", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 60 + }, + { + "color": "#d44a3a", + "value": 300 + } + ] + }, + "unit": "dtdurations" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -3598,45 +3555,32 @@ "x": 12, "y": 12 }, - "hideTimeOverride": true, "id": 35, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -3692,39 +3636,48 @@ ] } ], - "thresholds": "60,300", - "timeFrom": null, "title": "Longest AUTOVACUUM duration", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Frequent sequential scans on bigger tables should usually be avoided. Warn / Error thresholds: 10 / 100", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 10 + }, + { + "color": "#d44a3a", + "value": 100 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -3732,9 +3685,7 @@ "x": 18, "y": 12 }, - "hideTimeOverride": true, "id": 39, - "interval": null, "links": [ { "targetBlank": true, @@ -3742,41 +3693,31 @@ "url": "/d/tables-top?$__all_variables&viewPanel=4&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -3838,39 +3779,44 @@ ] } ], - "thresholds": "10,100", - "timeFrom": null, "title": "Seq. scans on >100 MB tables per minute (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": false, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "On non-temporary tables", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -3878,9 +3824,7 @@ "x": 0, "y": 14 }, - "hideTimeOverride": true, "id": 38, - "interval": null, "links": [ { "targetBlank": true, @@ -3888,41 +3832,31 @@ "url": "/d/tables-top?$__all_variables&viewPanel=6&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -3984,39 +3918,44 @@ ] } ], - "thresholds": "", - "timeFrom": null, "title": "INSERT-s per minute (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": false, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "On non-temporary tables", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -4024,9 +3963,7 @@ "x": 6, "y": 14 }, - "hideTimeOverride": true, "id": 40, - "interval": null, "links": [ { "targetBlank": true, @@ -4034,41 +3971,31 @@ "url": "/d/tables-top?$__all_variables&viewPanel=7&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -4130,39 +4057,44 @@ ] } ], - "thresholds": "", - "timeFrom": null, "title": "UPDATE-s per minute (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": false, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "On non-temporary tables", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -4170,9 +4102,7 @@ "x": 12, "y": 14 }, - "hideTimeOverride": true, "id": 41, - "interval": null, "links": [ { "targetBlank": true, @@ -4180,41 +4110,31 @@ "url": "/d/tables-top?$__all_variables&viewPanel=8&fullscreen" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -4276,39 +4196,48 @@ ] } ], - "thresholds": "", - "timeFrom": null, "title": "DELETE-s per minute (avg.)", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "avg" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Based on db_stats.backup_duration_s / pg_backup_start_time() [9.3+] function. N/A if no backup in progress.", - "format": "dtdurations", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 3600 + }, + { + "color": "#d44a3a", + "value": 36000 + } + ] + }, + "unit": "dtdurations" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -4318,43 +4247,31 @@ }, "hideTimeOverride": true, "id": 42, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -4410,39 +4327,49 @@ ] } ], - "thresholds": "3600,36000", "timeFrom": "$online_interval", "title": "Backup duration", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Max. age since last VACUUM FREEZE. Could hint at problems when going into 100s of millions", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 1, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 100000000 + }, + { + "color": "#d44a3a", + "value": 500000000 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -4450,45 +4377,32 @@ "x": 0, "y": 16 }, - "hideTimeOverride": true, "id": 47, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -4544,39 +4458,48 @@ ] } ], - "thresholds": "100000000,500000000", - "timeFrom": null, "title": "Max. table FREEZE age", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "In TX. Holds back VACUUM", - "format": "short", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 10000 + }, + { + "color": "#d44a3a", + "value": 100000 + } + ] + }, + "unit": "short" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -4584,9 +4507,7 @@ "x": 6, "y": 16 }, - "hideTimeOverride": true, "id": 43, - "interval": null, "links": [ { "targetBlank": true, @@ -4594,41 +4515,31 @@ "url": "/d/replication?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -4684,39 +4595,48 @@ ] } ], - "thresholds": "10000,100000", - "timeFrom": null, "title": "Max. XMIN horizon age", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "#bf1b00", - "#d44a3a" - ], - "datasource": null, - "decimals": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Inactive repl. slots accumulate WAL files until disk space runs out. Re-animate the replica or use pg_drop_replication_slot() to remove the slot so that Postgres can delete the un-needed WALs.", - "format": "none", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "decimals": 0, + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "#bf1b00", + "value": 1 + }, + { + "color": "#d44a3a", + "value": 1000 + } + ] + }, + "unit": "none" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -4726,7 +4646,6 @@ }, "hideTimeOverride": true, "id": 4, - "interval": null, "links": [ { "targetBlank": true, @@ -4734,41 +4653,31 @@ "url": "/d/replication?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -4818,39 +4727,48 @@ ] } ], - "thresholds": "1,1000", "timeFrom": "$online_interval", "title": "Inactive repl. slots", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "cacheTimeout": null, - "colorBackground": true, - "colorValue": false, - "colors": [ - "#299c46", - "#FA6400", - "#d44a3a" - ], - "datasource": null, - "decimals": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "\"Apply\" (data made visible to queries on replica) lag in bytes", - "format": "bytes", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "fieldConfig": { + "defaults": { + "mappings": [ + { + "options": { + "match": "null", + "result": { + "text": "N/A" + } + }, + "type": "special" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#299c46" + }, + { + "color": "#FA6400", + "value": 1000000 + }, + { + "color": "#d44a3a", + "value": 10000000 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] }, "gridPos": { "h": 2, @@ -4860,7 +4778,6 @@ }, "hideTimeOverride": true, "id": 46, - "interval": null, "links": [ { "targetBlank": true, @@ -4868,41 +4785,31 @@ "url": "/d/replication?$__all_variables" } ], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "options": {}, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false + "options": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "percentChangeColorMode": "standard", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showPercentChange": false, + "textMode": "auto", + "wideLayout": true }, - "tableColumn": "", + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -4952,22 +4859,15 @@ ] } ], - "thresholds": "1000000,10000000", "timeFrom": "$online_interval", "title": "Max. replication lag", - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - } - ], - "valueName": "current" + "type": "stat" }, { - "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 4, "w": 12, @@ -4975,15 +4875,25 @@ "y": 18 }, "id": 12, - "links": [], - "mode": "markdown", - "options": {}, + "options": { + "code": { + "language": "plaintext", + "showLineNumbers": false, + "showMiniMap": false + }, + "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", + "mode": "markdown" + }, + "pluginVersion": "12.0.0", "title": "", "transparent": true, "type": "text" }, { - "content": "### The preset threshold values (green / yellow / red) should be reviewed / adjusted!", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 4, "w": 12, @@ -4991,45 +4901,46 @@ "y": 18 }, "id": 48, - "links": [], - "mode": "markdown", - "options": {}, + "options": { + "code": { + "language": "plaintext", + "showLineNumbers": false, + "showMiniMap": false + }, + "content": "### The preset threshold values (green / yellow / red) should be reviewed / adjusted!", + "mode": "markdown" + }, + "pluginVersion": "12.0.0", "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 19, - "style": "dark", + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "allValue": null, "current": { - "text": null, - "value": null + "text": "demo", + "value": "demo" + }, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "datasource": null, "definition": "", - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tags": [], - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, @@ -5039,7 +4950,6 @@ "text": "10m", "value": "10m" }, - "hide": 0, "label": "Max. age for 'online' metrics", "name": "online_interval", "options": [ @@ -5071,7 +4981,6 @@ ], "query": "1m,3m,5m,10m,15m", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -5080,32 +4989,7 @@ "from": "now-30m", "to": "now" }, - "timepicker": { - "hidden": false, - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Health-check", "uid": "health-check", diff --git a/grafana/postgres/v12/index-overview.json b/grafana/postgres/v12/index-overview.json index 4e434ecec..887279310 100644 --- a/grafana/postgres/v12/index-overview.json +++ b/grafana/postgres/v12/index-overview.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 12, "links": [], "panels": [ { @@ -31,6 +32,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -43,8 +45,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -173,7 +174,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -253,6 +254,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -265,8 +267,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -361,7 +362,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -440,6 +441,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -452,8 +454,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -548,7 +549,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -627,6 +628,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -639,8 +641,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -758,7 +759,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -827,12 +828,10 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, - "editable": true, - "error": false, "gridPos": { "h": 4, "w": 24, @@ -847,23 +846,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, - "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "pluginVersion": "12.0.0", + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -871,10 +864,7 @@ "list": [ { "current": { - "selected": true, - "text": [ - "All" - ], + "text": "All", "value": [ "$__all" ] @@ -884,7 +874,6 @@ "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": true, "multi": true, "name": "dbname", @@ -892,10 +881,7 @@ "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'index_stats' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -903,34 +889,9 @@ "from": "now-1h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Index overview", "uid": "index-overview", - "version": 1, - "weekStart": "" + "version": 7 } \ No newline at end of file diff --git a/grafana/postgres/v12/pgbouncer-stats.json b/grafana/postgres/v12/pgbouncer-stats.json index 061fded61..b7aacd4d0 100644 --- a/grafana/postgres/v12/pgbouncer-stats.json +++ b/grafana/postgres/v12/pgbouncer-stats.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 2, "links": [], "panels": [ { @@ -47,8 +48,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -75,6 +75,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -86,7 +87,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "TPS", @@ -187,8 +188,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -215,6 +215,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -226,7 +227,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "QPS", @@ -327,8 +328,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -355,6 +355,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -366,7 +367,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "avg_query_runtime", @@ -454,8 +455,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -482,6 +482,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -493,7 +494,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "db_size_change_last_hour", @@ -594,8 +595,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -622,6 +622,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -633,7 +634,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "bytes_received", @@ -733,8 +734,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -761,6 +761,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -772,7 +773,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -862,6 +863,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -893,8 +895,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -940,11 +941,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "TPS", @@ -1033,6 +1035,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1064,8 +1067,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1126,11 +1128,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "Pool wait time", @@ -1209,6 +1212,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1239,8 +1243,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1332,11 +1335,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "QPS", @@ -1419,6 +1423,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1449,8 +1454,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1541,11 +1545,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "Incoming rate", @@ -1629,6 +1634,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1660,8 +1666,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1707,11 +1712,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "Avg. runtime", @@ -1789,6 +1795,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1820,8 +1827,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1897,11 +1903,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "Outgoing rate", @@ -1968,12 +1975,10 @@ "type": "timeseries" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, - "editable": true, - "error": false, "gridPos": { "h": 7, "w": 12, @@ -1988,24 +1993,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, - "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "pluginVersion": "12.0.0", + "title": "", "transparent": true, "type": "text" } ], - "refresh": false, - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -2013,9 +2011,7 @@ "list": [ { "current": { - "isNone": true, - "selected": false, - "text": "None", + "text": "", "value": "" }, "datasource": { @@ -2023,18 +2019,13 @@ "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'pgbouncer_stats' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -2042,34 +2033,9 @@ "from": "now-6h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "PgBouncer stats", "uid": "pgbouncer-stats", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/pgpool-stats.json b/grafana/postgres/v12/pgpool-stats.json index 58a10c0e5..baf718ea7 100644 --- a/grafana/postgres/v12/pgpool-stats.json +++ b/grafana/postgres/v12/pgpool-stats.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 33, "links": [], "panels": [ { @@ -43,8 +44,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -79,8 +79,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(245, 54, 54, 0.9)", - "value": null + "color": "rgba(245, 54, 54, 0.9)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -131,7 +130,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -192,6 +191,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -223,8 +223,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -253,11 +252,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -294,9 +294,9 @@ "type": "timeseries" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 6, @@ -312,23 +312,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, - "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "pluginVersion": "12.0.0", + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -336,20 +330,14 @@ "list": [ { "current": { - "selected": true, - "text": [ - "All" - ], - "value": [ - "$__all" - ] + "text": "All", + "value": "$__all" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "select distinct dbname from admin.all_distinct_dbname_metrics where metric = 'pgpool_stats';", - "hide": 0, "includeAll": true, "multi": true, "name": "dbname", @@ -357,23 +345,16 @@ "query": "select distinct dbname from admin.all_distinct_dbname_metrics where metric = 'pgpool_stats';", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "10m", "value": "10m" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -434,7 +415,6 @@ ], "query": "1m,2m,3m,5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -443,23 +423,9 @@ "from": "now-6h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Pgpool Stats", "uid": "pgpool-stats", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/postgres-version-overview.json b/grafana/postgres/v12/postgres-version-overview.json index 5417231d0..b0abaa2c3 100644 --- a/grafana/postgres/v12/postgres-version-overview.json +++ b/grafana/postgres/v12/postgres-version-overview.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 7, "links": [], "panels": [ { @@ -43,8 +44,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -80,8 +80,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(245, 54, 54, 0.9)", - "value": null + "color": "rgba(245, 54, 54, 0.9)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -117,7 +116,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -186,9 +185,9 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 8, @@ -204,45 +203,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, - "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "format": "time_series", - "group": [], - "metricColumn": "none", - "rawQuery": false, - "refId": "A", - "select": [ - [ - { - "params": [ - "value" - ], - "type": "column" - } - ] - ], - "timeColumn": "time", - "where": [ - { - "name": "$__timeFilter", - "params": [], - "type": "macro" - } - ] - } - ], + "pluginVersion": "12.0.0", + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -250,10 +221,7 @@ "list": [ { "current": { - "selected": true, - "text": [ - "All" - ], + "text": "All", "value": [ "$__all" ] @@ -263,7 +231,6 @@ "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'settings' ORDER BY 1;", - "hide": 0, "includeAll": true, "multi": true, "name": "dbname", @@ -271,38 +238,25 @@ "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'settings' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { - "selected": false, - "text": "160002", - "value": "160002" + "text": "170004", + "value": "170004" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT (data->'server_version_num')::int FROM settings WHERE time > now() - '24h'::interval ORDER BY 1 DESC", - "hide": 0, "includeAll": false, - "multi": false, "name": "lower_than_server_version_num", "options": [], "query": "SELECT DISTINCT (data->'server_version_num')::int FROM settings WHERE time > now() - '24h'::interval ORDER BY 1 DESC", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -310,34 +264,9 @@ "from": "now-6h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Postgres Version Overview", "uid": "postgres-version-overview", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/recommendations.json b/grafana/postgres/v12/recommendations.json index 3c5234084..004b4b6a8 100644 --- a/grafana/postgres/v12/recommendations.json +++ b/grafana/postgres/v12/recommendations.json @@ -19,6 +19,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 14, "links": [], "panels": [ { @@ -44,8 +45,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -95,7 +95,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -162,8 +162,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -213,7 +212,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -280,8 +279,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -331,7 +329,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -398,8 +396,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -449,7 +446,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -516,8 +513,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -567,7 +563,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -634,8 +630,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -752,8 +747,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -870,8 +864,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -988,8 +981,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1106,8 +1098,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1202,11 +1193,11 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, "description": "", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 5, "w": 24, @@ -1221,46 +1212,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "format": "table", - "group": [], - "metricColumn": "none", - "rawQuery": true, - "rawSql": "SELECT\n dbname,\n data->>'major_ver' AS pg_major_ver,\n tag_data->>'object_name' AS object_name,\n data->>'recommendation' AS recommendation,\n data->>'extra_info' AS extra_info\nFROM\n recommendations\nWHERE\n time IN (SELECT max(time) FROM recommendations WHERE $__timeFilter(time) GROUP BY dbname)\n AND dbname IN ($dbname)\n AND tag_data->>'reco_topic' = 'drop_index'\nORDER BY\n dbname, object_name", - "refId": "A", - "select": [ - [ - { - "params": [ - "value" - ], - "type": "column" - } - ] - ], - "timeColumn": "time", - "where": [ - { - "name": "$__timeFilter", - "params": [], - "type": "macro" - } - ] - } - ], + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1278,8 +1240,6 @@ "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM recommendations WHERE time > now() - '2d'::interval ORDER BY 1;", - "error": {}, - "hide": 0, "includeAll": true, "multi": true, "name": "dbname", @@ -1287,12 +1247,7 @@ "query": "SELECT DISTINCT dbname FROM recommendations WHERE time > now() - '2d'::interval ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -1300,23 +1255,9 @@ "from": "now-24h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Recommendations", "uid": "recommendations", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/replication.json b/grafana/postgres/v12/replication.json index c36b77cd7..8c3c87490 100644 --- a/grafana/postgres/v12/replication.json +++ b/grafana/postgres/v12/replication.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 25, "links": [], "panels": [ { @@ -47,8 +48,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "#bf1b00", @@ -78,6 +78,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -89,7 +90,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -177,8 +178,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "#bf1b00", @@ -208,6 +208,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -219,7 +220,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -307,8 +308,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -338,6 +338,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -349,7 +350,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -443,8 +444,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -470,6 +470,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -481,7 +482,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -575,8 +576,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -606,6 +606,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -617,7 +618,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -705,8 +706,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -736,6 +736,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -747,7 +748,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -841,8 +842,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -872,6 +872,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -883,7 +884,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -977,8 +978,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1008,6 +1008,7 @@ "graphMode": "none", "justifyMode": "auto", "orientation": "horizontal", + "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" @@ -1019,7 +1020,7 @@ "textMode": "auto", "wideLayout": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1104,6 +1105,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1135,8 +1137,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1166,11 +1167,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "[[tag_dbname]] slot=[[tag_slot_name]]", @@ -1267,6 +1269,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1298,8 +1301,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1329,11 +1331,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "[[tag_dbname]] [[tag_application_name]] [[tag_client_info]]", @@ -1436,6 +1439,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1467,8 +1471,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1498,11 +1501,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "[[tag_dbname]] [[tag_application_name]] [[tag_client_info]]", @@ -1605,6 +1609,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -1636,8 +1641,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1667,11 +1671,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "[[tag_dbname]] [[tag_slot_name]]", @@ -1757,9 +1762,9 @@ "type": "timeseries" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 4, @@ -1775,24 +1780,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, - "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "pluginVersion": "12.0.0", + "title": "", "transparent": true, "type": "text" } ], - "refresh": false, - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1800,10 +1798,7 @@ "list": [ { "current": { - "selected": true, - "text": [ - "All" - ], + "text": "All", "value": [ "$__all" ] @@ -1813,7 +1808,6 @@ "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": true, "multi": true, "name": "dbname", @@ -1821,12 +1815,7 @@ "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric IN ('replication', 'replication_slots') ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -1834,34 +1823,9 @@ "from": "now-3h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Replication", "uid": "replication", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/server-log-events.json b/grafana/postgres/v12/server-log-events.json index 0459fd35f..eabfd76f5 100644 --- a/grafana/postgres/v12/server-log-events.json +++ b/grafana/postgres/v12/server-log-events.json @@ -19,6 +19,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 8, "links": [], "panels": [ { @@ -39,6 +40,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -71,8 +73,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -122,7 +123,6 @@ "y": 0 }, "id": 2, - "interval": "", "options": { "legend": { "calcs": [ @@ -133,11 +133,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -191,6 +192,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -223,8 +225,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -274,7 +275,6 @@ "y": 10 }, "id": 3, - "interval": "", "options": { "legend": { "calcs": [ @@ -285,11 +285,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -347,8 +348,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -442,7 +442,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -508,8 +508,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -603,7 +602,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -648,9 +647,9 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 8, @@ -669,20 +668,14 @@ "mode": "markdown" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -690,10 +683,7 @@ "list": [ { "current": { - "selected": true, - "text": [ - "All" - ], + "text": "All", "value": [ "$__all" ] @@ -703,7 +693,6 @@ "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'server_log_event_counts' ORDER BY 1;", - "hide": 0, "includeAll": true, "multi": true, "name": "dbname", @@ -711,23 +700,16 @@ "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'server_log_event_counts' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "5m", "value": "5m" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -778,7 +760,6 @@ ], "query": "1m,5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -787,23 +768,9 @@ "from": "now-6h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Server Log Events", "uid": "server-log-events", - "version": 2, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/sessions-overview.json b/grafana/postgres/v12/sessions-overview.json index 3f584dd5c..db474d622 100644 --- a/grafana/postgres/v12/sessions-overview.json +++ b/grafana/postgres/v12/sessions-overview.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 19, "links": [], "panels": [ { @@ -37,6 +38,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -68,8 +70,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -88,7 +89,6 @@ "y": 0 }, "id": 2, - "interval": "", "options": { "legend": { "calcs": [ @@ -99,11 +99,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -186,6 +187,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -217,8 +219,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -278,11 +279,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -335,6 +337,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -367,8 +370,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -428,11 +430,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -485,6 +488,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -516,8 +520,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -592,11 +595,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -649,6 +653,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -680,8 +685,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -726,11 +730,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -814,8 +819,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -996,8 +1000,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1116,8 +1119,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1203,9 +1205,9 @@ "type": "timeseries" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 3, @@ -1221,46 +1223,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "format": "time_series", - "group": [], - "metricColumn": "none", - "rawQuery": false, - "rawSql": "SELECT\n $__time(time_column),\n value1\nFROM\n metric_table\nWHERE\n $__timeFilter(time_column)\n", - "refId": "A", - "select": [ - [ - { - "params": [ - "value" - ], - "type": "column" - } - ] - ], - "timeColumn": "time", - "where": [ - { - "name": "$__timeFilter", - "params": [], - "type": "macro" - } - ] - } - ], + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1268,40 +1241,30 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'backends' ORDER BY 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'backends' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "5m", "value": "5m" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -1372,7 +1335,6 @@ ], "query": "1s,1m,5m,10m,15m,30m,1h,6h,12h,1d,7d,14d,30d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -1381,23 +1343,9 @@ "from": "now-12h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Sessions overview", "uid": "sessions-overview", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/show-plans-realtime.json b/grafana/postgres/v12/show-plans-realtime.json index a2a6a5445..5fb448169 100644 --- a/grafana/postgres/v12/show-plans-realtime.json +++ b/grafana/postgres/v12/show-plans-realtime.json @@ -3,7 +3,10 @@ "list": [ { "builtIn": 1, - "datasource": "-- Grafana --", + "datasource": { + "type": "datasource", + "uid": "grafana" + }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", @@ -14,16 +17,100 @@ }, "description": "Based on the pg_show_plans extension", "editable": true, - "gnetId": null, + "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, + "id": 20, "links": [], "panels": [ { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Based on the \"pg_show_plans\" extension and \"pg_stat_activity\" infos", - "fontSize": "100%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byRegexp", + "options": "/duration/" + }, + "properties": [ + { + "id": "unit", + "value": "s" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "plan" + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 22, "w": 24, @@ -31,67 +118,25 @@ "y": 0 }, "id": 2, - "options": {}, - "pageSize": null, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "/duration/", - "thresholds": [], - "type": "number", - "unit": "s" + "show": false }, - { - "alias": "", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "plan", - "preserveFormat": true, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "query", - "preserveFormat": true, - "thresholds": [], - "type": "string", - "unit": "short" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "metricColumn": "none", @@ -118,15 +163,14 @@ ] } ], - "timeFrom": null, - "timeShift": null, "title": "Realtime execution plans", - "transform": "table", "type": "table" }, { - "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "datasource": null, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 4, "w": 24, @@ -134,43 +178,46 @@ "y": 22 }, "id": 4, - "mode": "markdown", - "options": {}, - "timeFrom": null, - "timeShift": null, + "options": { + "code": { + "language": "plaintext", + "showLineNumbers": false, + "showMiniMap": false + }, + "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", + "mode": "markdown" + }, + "pluginVersion": "12.0.0", "title": "", "transparent": true, "type": "text" } ], + "preload": false, "refresh": "5s", - "schemaVersion": 20, - "style": "dark", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "allValue": null, - "datasource": null, + "current": { + "text": "", + "value": "" + }, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'show_plans_realtime' ORDER BY 1;", - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'show_plans_realtime' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tags": [], - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" } ] }, @@ -178,20 +225,7 @@ "from": "now-15m", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Realtime execution plans", "uid": "realtime-execution-plans", diff --git a/grafana/postgres/v12/single-query-details.json b/grafana/postgres/v12/single-query-details.json index 3a68b662b..7767cd457 100644 --- a/grafana/postgres/v12/single-query-details.json +++ b/grafana/postgres/v12/single-query-details.json @@ -19,6 +19,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 26, "links": [], "panels": [ { @@ -39,6 +40,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -70,8 +72,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -101,11 +102,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "avg_runtime", @@ -195,6 +197,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -225,8 +228,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -256,11 +258,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "calls", @@ -355,6 +358,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -386,8 +390,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -417,11 +420,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "total_runtime", @@ -516,6 +520,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -547,8 +552,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -578,11 +582,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "sb_hit_ratio", @@ -672,6 +677,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -703,8 +709,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -732,11 +737,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "temp_blks_written", @@ -863,8 +869,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1024,8 +1029,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1141,8 +1145,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1293,9 +1296,9 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 7, @@ -1310,25 +1313,18 @@ "showLineNumbers": false, "showMiniMap": false }, - "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", + "mode": "markdown" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "title": "", "transparent": true, "type": "text" } ], - "refresh": false, - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1336,67 +1332,48 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_statements' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { - "isNone": true, - "selected": false, - "text": "None", - "value": "" + "text": "1488892720291066843", + "value": "1488892720291066843" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "select distinct tag_data->>'queryid' from stat_statements WHERE time > current_date -3 and dbname = '$dbname' order by 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "queryid", "options": [], "query": "select distinct tag_data->>'queryid' from stat_statements WHERE time > current_date -3 and dbname = '$dbname' order by 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "30m", "value": "30m" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -1447,7 +1424,6 @@ ], "query": "1m,5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -1456,34 +1432,9 @@ "from": "now-12h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Single query details", "uid": "single-query-details", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/sproc-details.json b/grafana/postgres/v12/sproc-details.json index 89e8b2cc9..be97e49b3 100644 --- a/grafana/postgres/v12/sproc-details.json +++ b/grafana/postgres/v12/sproc-details.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 23, "links": [], "panels": [ { @@ -37,6 +38,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -68,8 +70,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -99,11 +100,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "none" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "calls", @@ -182,56 +184,92 @@ "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, - "decimals": 3, "fieldConfig": { "defaults": { - "links": [] + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "decimals": 3, + "links": [], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "ms" }, "overrides": [] }, - "fill": 1, - "fillGradient": 0, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 7 }, - "hiddenSeries": false, "id": 2, "interval": "2m", - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null as zero", "options": { - "alertThreshold": true + "alertThreshold": true, + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "none" + } }, - "percentage": false, - "pluginVersion": "10.4.1", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { "alias": "total_time", @@ -306,39 +344,13 @@ ] } ], - "thresholds": [], - "timeRegions": [], "title": "Avg. runtime ($agg_interval avg.)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 3, - "format": "ms", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": false - } - ], - "yaxis": { - "align": false - } + "type": "timeseries" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -346,66 +358,48 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'sproc_stats' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { - "selected": false, - "text": "_timescaledb_functions.policy_job_error_retention", - "value": "_timescaledb_functions.policy_job_error_retention" + "text": "public.get_load_average", + "value": "public.get_load_average" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "select distinct tag_data->>'function_full_name' from sproc_stats where time > current_date-7 and dbname = '$dbname' and tag_data ? 'function_full_name' order by 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "sproc_name", "options": [], "query": "select distinct tag_data->>'function_full_name' from sproc_stats where time > current_date-7 and dbname = '$dbname' and tag_data ? 'function_full_name' order by 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "10m", "value": "10m" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -456,7 +450,6 @@ ], "query": "1m,5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -465,34 +458,9 @@ "from": "now-3h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Sproc details", "uid": "sproc-details", - "version": 3, - "weekStart": "" + "version": 11 } \ No newline at end of file diff --git a/grafana/postgres/v12/sprocs-top.json b/grafana/postgres/v12/sprocs-top.json index 44751be4d..5a512cdb2 100644 --- a/grafana/postgres/v12/sprocs-top.json +++ b/grafana/postgres/v12/sprocs-top.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 28, "links": [], "panels": [ { @@ -43,8 +44,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -180,7 +180,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -271,8 +271,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -408,7 +407,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -499,8 +498,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -632,7 +630,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -723,8 +721,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -860,7 +857,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -951,8 +948,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1088,7 +1084,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -1157,9 +1153,9 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 8, @@ -1178,42 +1174,14 @@ "mode": "html" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "format": "time_series", - "group": [], - "metricColumn": "none", - "rawQuery": false, - "refId": "A", - "select": [ - [ - { - "params": [ - "value" - ], - "type": "column" - } - ] - ], - "timeColumn": "time", - "where": [ - { - "name": "$__timeFilter", - "params": [], - "type": "macro" - } - ] - } - ], + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1221,39 +1189,28 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'sproc_stats' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { - "selected": false, "text": "5", "value": "5" }, - "hide": 0, "includeAll": false, - "multi": false, "name": "top", "options": [ { @@ -1303,7 +1260,6 @@ } ], "query": "1,3,5,10,15,20,30,40,50", - "skipUrlSync": false, "type": "custom" } ] @@ -1312,34 +1268,9 @@ "from": "now-3h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Top Sprocs", "uid": "top-sprocs", - "version": 1, - "weekStart": "" + "version": 11 } \ No newline at end of file diff --git a/grafana/postgres/v12/stat-activity-realtime.json b/grafana/postgres/v12/stat-activity-realtime.json index 4fa5603d5..a9ee30ef2 100644 --- a/grafana/postgres/v12/stat-activity-realtime.json +++ b/grafana/postgres/v12/stat-activity-realtime.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 24, "links": [], "panels": [ { @@ -43,8 +44,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -102,8 +102,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -147,8 +146,7 @@ "mode": "absolute", "steps": [ { - "color": "rgba(50, 172, 45, 0.97)", - "value": null + "color": "rgba(50, 172, 45, 0.97)" }, { "color": "#C4162A", @@ -203,7 +201,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -248,8 +246,9 @@ "type": "table" } ], + "preload": false, "refresh": "5s", - "schemaVersion": 39, + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -257,9 +256,7 @@ "list": [ { "current": { - "isNone": true, - "selected": false, - "text": "None", + "text": "", "value": "" }, "datasource": { @@ -267,27 +264,19 @@ "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_activity_realtime' ORDER BY 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_activity_realtime' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { "text": "1", "value": "1" }, - "hide": 0, "name": "min_duration_s", "options": [ { @@ -297,7 +286,6 @@ } ], "query": "1", - "skipUrlSync": false, "type": "textbox" } ] @@ -307,12 +295,7 @@ "to": "now" }, "timepicker": { - "hidden": false, "refresh_intervals": [ - "1s", - "2s", - "3s", - "4s", "5s", "10s", "30s", @@ -324,6 +307,5 @@ "timezone": "", "title": "Stat Activity Realtime", "uid": "stat-activity-realtime", - "version": 1, - "weekStart": "" + "version": 11 } \ No newline at end of file diff --git a/grafana/postgres/v12/stat-activity.json b/grafana/postgres/v12/stat-activity.json index 4020920ef..6ecf37b50 100644 --- a/grafana/postgres/v12/stat-activity.json +++ b/grafana/postgres/v12/stat-activity.json @@ -18,16 +18,167 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 32, "links": [], "panels": [ { - "columns": [], "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "description": "Top 25 longest running queries from pg_stat_activity. Query texts are compacted", - "fontSize": "100%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "pid" + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "duration" + }, + "properties": [ + { + "id": "unit", + "value": "s" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.cellOptions", + "value": { + "type": "color-text" + } + }, + { + "id": "custom.align" + }, + { + "id": "thresholds", + "value": { + "mode": "absolute", + "steps": [ + { + "color": "rgba(50, 172, 45, 0.97)" + }, + { + "color": "rgba(237, 129, 40, 0.89)", + "value": 60 + }, + { + "color": "rgba(245, 54, 54, 0.9)", + "value": 300 + } + ] + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "waiting" + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.cellOptions", + "value": { + "type": "color-text" + } + }, + { + "id": "custom.align" + }, + { + "id": "thresholds", + "value": { + "mode": "absolute", + "steps": [ + { + "color": "rgba(50, 172, 45, 0.97)" + }, + { + "color": "#C4162A", + "value": 1 + }, + { + "color": "rgba(245, 54, 54, 0.9)", + "value": 2 + } + ] + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "blocking_pids" + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 24, "w": 24, @@ -35,93 +186,19 @@ "y": 0 }, "id": 2, - "showHeader": true, - "sort": { - "desc": false - }, - "styles": [ - { - "alias": "", - "align": "auto", - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 2, - "pattern": "pid", - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "align": "auto", - "colorMode": "value", - "colors": [ - "rgba(50, 172, 45, 0.97)", - "rgba(237, 129, 40, 0.89)", - "rgba(245, 54, 54, 0.9)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "duration", - "thresholds": [ - "60", - "300" - ], - "type": "number", - "unit": "s" - }, - { - "alias": "", - "align": "auto", - "colorMode": "value", - "colors": [ - "rgba(50, 172, 45, 0.97)", - "#C4162A", - "rgba(245, 54, 54, 0.9)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "waiting", - "thresholds": [ - "1", - "2" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "type": "string", - "unit": "short", - "valueMaps": [ - { - "text": "no", - "value": "0" - }, - { - "text": "yes", - "value": "1" - } - ] + "show": false }, - { - "alias": "", - "align": "auto", - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "blocking_pids", - "thresholds": [], - "type": "string", - "unit": "short", - "valueMaps": [] - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -155,12 +232,12 @@ } ], "title": "Stat Activity", - "transform": "table", - "type": "table-old" + "type": "table" } ], + "preload": false, "refresh": "5s", - "schemaVersion": 39, + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -168,9 +245,7 @@ "list": [ { "current": { - "isNone": true, - "selected": false, - "text": "None", + "text": "", "value": "" }, "datasource": { @@ -178,27 +253,19 @@ "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_activity_realtime' ORDER BY 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_activity_realtime' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { "text": "1", "value": "1" }, - "hide": 0, "name": "min_duration_s", "options": [ { @@ -208,7 +275,6 @@ } ], "query": "1", - "skipUrlSync": false, "type": "textbox" } ] @@ -218,12 +284,7 @@ "to": "now" }, "timepicker": { - "hidden": false, "refresh_intervals": [ - "1s", - "2s", - "3s", - "4s", "5s", "10s", "30s", @@ -235,6 +296,5 @@ "timezone": "", "title": "Stat Activity", "uid": "stat-activity", - "version": 1, - "weekStart": "" + "version": 11 } \ No newline at end of file diff --git a/grafana/postgres/v12/stat-statements-sql-search.json b/grafana/postgres/v12/stat-statements-sql-search.json index f26fb2c38..e51b2dd48 100644 --- a/grafana/postgres/v12/stat-statements-sql-search.json +++ b/grafana/postgres/v12/stat-statements-sql-search.json @@ -15,10 +15,10 @@ } ] }, - "description": "", "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 5, "links": [], "panels": [ { @@ -44,8 +44,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -154,7 +153,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -199,9 +198,9 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 5, @@ -217,23 +216,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, - "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "pluginVersion": "12.0.0", + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -241,36 +234,27 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_statements' ORDER BY 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_statements' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { "text": "", "value": "" }, - "hide": 0, "label": "SQL search fragment (case insensitive, 3 char min.)", "name": "sql_fragment", "options": [ @@ -281,7 +265,6 @@ } ], "query": "", - "skipUrlSync": false, "type": "textbox" }, { @@ -289,11 +272,9 @@ "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "12h", "value": "12h" }, - "hide": 0, "label": "Having some executions within last", "name": "calls_interval", "options": [ @@ -340,7 +321,6 @@ ], "query": "30m,1h,6h,12h,1d,7d,14d,30d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -349,24 +329,9 @@ "from": "now-12h", "to": "now" }, - "timepicker": { - "hidden": false, - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Stat Statements SQL Search", "uid": "stat-statements-sql-search", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/stat-statements-top-fast.json b/grafana/postgres/v12/stat-statements-top-fast.json index dd34d2760..d55d39322 100644 --- a/grafana/postgres/v12/stat-statements-top-fast.json +++ b/grafana/postgres/v12/stat-statements-top-fast.json @@ -3,7 +3,10 @@ "list": [ { "builtIn": 1, - "datasource": "-- Grafana --", + "datasource": { + "type": "datasource", + "uid": "grafana" + }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", @@ -14,16 +17,194 @@ }, "description": "Assumes no pg_stat_statements reset appeared in the selected time frame", "editable": true, - "gnetId": null, + "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, + "id": 9, "links": [], "panels": [ { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "", - "fontSize": "90%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "Total runtime" + }, + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "approx_pct_db_total_time" + }, + "properties": [ + { + "id": "unit", + "value": "percent" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Avg. runtime" + }, + "properties": [ + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Calls" + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -31,139 +212,26 @@ "y": 0 }, "id": 16, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "link": false, - "linkTargetBlank": true, - "linkTooltip": "", - "linkUrl": "", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "sanitize": false, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Total runtime", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "ms" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "preserveFormat": false, - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" + "show": false }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "approx_pct_db_total_time", - "thresholds": [], - "type": "number", - "unit": "percent" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "Avg. runtime", - "thresholds": [], - "type": "number", - "unit": "ms" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": null, - "mappingType": 1, - "pattern": "Calls", - "thresholds": [], - "type": "number", - "unit": "short" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "ass", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -214,14 +282,157 @@ } ], "title": "Top queries by total runtime", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "", - "fontSize": "90%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "Avg. runtime" + }, + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Total time" + }, + "properties": [ + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -229,105 +440,26 @@ "y": 7 }, "id": 15, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "link": false, - "linkTargetBlank": true, - "linkTooltip": "", - "linkUrl": "", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "sanitize": false, - "thresholds": [], - "type": "string", - "unit": "short" + "show": false }, - { - "alias": "Avg. runtime", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "ms" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "preserveFormat": false, - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "Total time", - "thresholds": [], - "type": "number", - "unit": "ms" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "ass", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -378,14 +510,176 @@ } ], "title": "Top queries by avg. runtime", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "", - "fontSize": "90%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "Calls " + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Total time" + }, + "properties": [ + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Avg. runtime" + }, + "properties": [ + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -393,122 +687,26 @@ "y": 14 }, "id": 14, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "link": false, - "linkTargetBlank": true, - "linkTooltip": "", - "linkUrl": "", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "sanitize": false, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Calls ", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "short" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "preserveFormat": false, - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "Total time", - "thresholds": [], - "type": "number", - "unit": "ms" + "show": false }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "Avg. runtime", - "thresholds": [], - "type": "number", - "unit": "ms" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "ass", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -559,14 +757,157 @@ } ], "title": "Top queries by calls", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "total_time - blk_read_time -blk_write_time. Requires track_io_timing=on", - "fontSize": "100%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "CPU time" + }, + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": false, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Avg. runtime" + }, + "properties": [ + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -574,97 +915,25 @@ "y": 21 }, "id": 13, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "CPU time", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "ms" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" + "show": false }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "Avg. runtime", - "thresholds": [], - "type": "number", - "unit": "ms" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -715,14 +984,18 @@ } ], "title": "Top queries by CPU time", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Does not include Shared Buffer activities. Same as 'By total runtime' if no direct IO was performed. Requires track_io_timing=on", - "fontSize": "100%", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, @@ -730,97 +1003,13 @@ "y": 28 }, "id": 12, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "IO time", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "ms" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "Total time", - "thresholds": [], - "type": "number", - "unit": "ms" - } - ], + "options": {}, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -871,14 +1060,18 @@ } ], "title": "Top queries by direct (backend) IO", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Shared buffer + temp buffer reading / writing", - "fontSize": "100%", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, @@ -886,115 +1079,13 @@ "y": 35 }, "id": 11, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Block bandwith", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "decbytes" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "Per call", - "thresholds": [], - "type": "number", - "unit": "bytes" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "Avg. runtime", - "thresholds": [], - "type": "number", - "unit": "ms" - } - ], + "options": {}, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -1045,14 +1136,18 @@ } ], "title": "Top by block bandwith (assuming 8K blocks)", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Based on pg_stat_statements.temp_blks_written", - "fontSize": "100%", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, @@ -1060,132 +1155,13 @@ "y": 42 }, "id": 17, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Temp blocks written", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "decbytes" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "Per call", - "thresholds": [], - "type": "number", - "unit": "bytes" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "mappingType": 1, - "pattern": "/runtime/", - "thresholds": [], - "type": "number", - "unit": "ms" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "Temp blocks read", - "thresholds": [], - "type": "number", - "unit": "bytes" - } - ], + "options": {}, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -1236,14 +1212,13 @@ } ], "title": "Top by temp blocks (assuming 8K blocks)", - "transform": "table", "type": "table" }, { - "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "datasource": null, - "editable": true, - "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 3, "w": 12, @@ -1251,29 +1226,19 @@ "y": 49 }, "id": 4, - "links": [], - "mode": "markdown", + "options": {}, "title": "", "transparent": true, "type": "text" }, { - "cacheTimeout": null, - "colorBackground": false, - "colorValue": true, - "colors": [ - "#299c46", - "rgba(237, 129, 40, 0.89)", - "#d44a3a" - ], - "datasource": null, - "format": "none", - "gauge": { - "maxValue": 100, - "minValue": 0, - "show": false, - "thresholdLabels": false, - "thresholdMarkers": true + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 3, @@ -1282,44 +1247,14 @@ "y": 49 }, "id": 18, - "interval": null, - "links": [], - "mappingType": 1, - "mappingTypes": [ - { - "name": "value to text", - "value": 1 - }, - { - "name": "range to text", - "value": 2 - } - ], "maxDataPoints": 100, - "nullPointMode": "connected", - "nullText": null, - "postfix": "", - "postfixFontSize": "50%", - "prefix": "", - "prefixFontSize": "50%", - "rangeMaps": [ - { - "from": "null", - "text": "N/A", - "to": "null" - } - ], - "sparkline": { - "fillColor": "rgba(31, 118, 189, 0.18)", - "full": false, - "lineColor": "rgb(31, 120, 193)", - "show": false, - "ymax": null, - "ymin": null - }, - "tableColumn": "", + "options": {}, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -1346,76 +1281,43 @@ ] } ], - "thresholds": "1,1", "title": "", "transparent": true, - "type": "singlestat", - "valueFontSize": "80%", - "valueMaps": [ - { - "op": "=", - "text": "N/A", - "value": "null" - }, - { - "op": "=", - "text": "", - "value": "0" - }, - { - "op": "=", - "text": "WARNING: global stats reset detected for selected time range, results are unreliable - use the slower \"Stat Statements Top\" dashboard", - "value": "1" - } - ], - "valueName": "avg" + "type": "stat" } ], - "schemaVersion": 22, - "style": "dark", + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "allValue": null, "current": { - "tags": [], - "text": null, - "value": null + "text": "demo", + "value": "demo" + }, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "datasource": null, "definition": "", - "hide": 0, "includeAll": false, - "index": -1, - "label": null, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_statements' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": null, - "tags": [], - "tagsQuery": null, - "type": "query", - "useTags": false + "type": "query" }, { - "allValue": null, "current": { - "tags": [], "text": "5", "value": "5" }, - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "top", "options": [ { @@ -1429,7 +1331,7 @@ "value": "3" }, { - "selected": false, + "selected": true, "text": "5", "value": "5" }, @@ -1459,26 +1361,20 @@ "value": "40" }, { - "selected": true, + "selected": false, "text": "50", "value": "50" } ], "query": "1,3,5,10,15,20,30,40,50", - "skipUrlSync": false, "type": "custom" }, { - "allValue": null, "current": { - "tags": [], "text": "yes", "value": "yes" }, - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "hide_pgwatch_generated", "options": [ { @@ -1493,7 +1389,6 @@ } ], "query": "yes,no", - "skipUrlSync": false, "type": "custom" } ] @@ -1502,36 +1397,9 @@ "from": "now-6h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Stat statements Top (Fast)", "uid": "stat-statements-top-fast", - "variables": { - "list": [] - }, "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/stat-statements-top-visual.json b/grafana/postgres/v12/stat-statements-top-visual.json index 376ede502..4ca51072a 100644 --- a/grafana/postgres/v12/stat-statements-top-visual.json +++ b/grafana/postgres/v12/stat-statements-top-visual.json @@ -3,7 +3,10 @@ "list": [ { "builtIn": 1, - "datasource": "-- Grafana --", + "datasource": { + "type": "datasource", + "uid": "grafana" + }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", @@ -13,45 +16,80 @@ ] }, "editable": true, - "gnetId": null, + "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, + "id": 4, "links": [], "panels": [ { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Assumes that pg_stat_statement data has not been reset in the selected time frame. Click on the graph data links for the 'Query details' view.", - "fill": 1, - "fillGradient": 0, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "short" + }, + "overrides": [] + }, "gridPos": { "h": 12, "w": 24, "x": 0, "y": 0 }, - "hiddenSeries": false, "id": 2, - "interval": "", - "legend": { - "alignAsTable": true, - "avg": true, - "current": false, - "max": true, - "min": false, - "show": true, - "sort": "max", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { "dataLinks": [ { @@ -59,18 +97,29 @@ "title": "Query details", "url": "/d/single-query-details?$__all_variables&var-queryid=${__series.name}&${__url_time_range}" } - ] + ], + "legend": { + "calcs": [ + "mean", + "max" + ], + "displayMode": "table", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -97,82 +146,78 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Top $top queries by calls", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": null, - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Assumes that pg_stat_statement data has not been reset in the selected time frame. Click on the graph data links for the 'Query details' view.", - "fill": 1, - "fillGradient": 0, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "ms" + }, + "overrides": [] + }, "gridPos": { "h": 12, "w": 24, "x": 0, "y": 12 }, - "hiddenSeries": false, "id": 3, - "interval": "", - "legend": { - "alignAsTable": true, - "avg": true, - "current": false, - "max": true, - "min": false, - "show": true, - "sort": "max", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { "dataLinks": [ { @@ -180,18 +225,29 @@ "title": "Query details", "url": "/d/single-query-details?$__all_variables&var-queryid=${__series.name}&${__url_time_range}" } - ] + ], + "legend": { + "calcs": [ + "mean", + "max" + ], + "displayMode": "table", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -218,51 +274,14 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Top $top queries by total time", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": null, - "format": "ms", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "datasource": null, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 8, "w": 12, @@ -270,59 +289,55 @@ "y": 24 }, "id": 5, - "mode": "markdown", - "options": {}, - "timeFrom": null, - "timeShift": null, + "options": { + "code": { + "language": "plaintext", + "showLineNumbers": false, + "showMiniMap": false + }, + "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", + "mode": "markdown" + }, + "pluginVersion": "12.0.0", "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 22, - "style": "dark", + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "allValue": null, "current": { - "selected": true, - "text": null, - "value": null + "text": "demo", + "value": "demo" + }, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "datasource": null, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_statements' ORDER BY 1;", - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_statements' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tags": [], - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "15m", "value": "15m" }, - "hide": 0, - "label": null, "name": "agg_interval", "options": [ { @@ -368,20 +383,14 @@ ], "query": "5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" }, { - "allValue": null, "current": { - "selected": true, "text": "5", "value": "5" }, - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "top", "options": [ { @@ -416,7 +425,6 @@ } ], "query": "1,3,5,7,10,15", - "skipUrlSync": false, "type": "custom" } ] @@ -425,22 +433,9 @@ "from": "now-6h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Stat Statements Top (Visual)", "uid": "stat-statements-top-visual", - "version": 1 + "version": 6 } \ No newline at end of file diff --git a/grafana/postgres/v12/stat-statements-top.json b/grafana/postgres/v12/stat-statements-top.json index 7291363f8..3b44bf93a 100644 --- a/grafana/postgres/v12/stat-statements-top.json +++ b/grafana/postgres/v12/stat-statements-top.json @@ -3,7 +3,10 @@ "list": [ { "builtIn": 1, - "datasource": "-- Grafana --", + "datasource": { + "type": "datasource", + "uid": "grafana" + }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", @@ -13,16 +16,160 @@ ] }, "editable": true, - "gnetId": null, + "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, + "id": 25, "links": [], "panels": [ { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "", - "fontSize": "90%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "Total runtime" + }, + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "approx_pct_db_total_time" + }, + "properties": [ + { + "id": "unit", + "value": "percent" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -30,105 +177,26 @@ "y": 0 }, "id": 5, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "link": false, - "linkTargetBlank": true, - "linkTooltip": "", - "linkUrl": "", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "sanitize": false, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Total runtime", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "ms" + "show": false }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "preserveFormat": false, - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "mappingType": 1, - "pattern": "approx_pct_db_total_time", - "thresholds": [], - "type": "number", - "unit": "percent" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "ass", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -178,14 +246,138 @@ } ], "title": "Top queries by total runtime", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "", - "fontSize": "90%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "Avg. runtime" + }, + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -193,88 +385,26 @@ "y": 7 }, "id": 6, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "link": false, - "linkTargetBlank": true, - "linkTooltip": "", - "linkUrl": "", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "sanitize": false, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Avg. runtime", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "ms" + "show": false }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "preserveFormat": false, - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "ass", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -324,14 +454,138 @@ } ], "title": "Top queries by avg. runtime", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "", - "fontSize": "90%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "Calls " + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -339,88 +593,26 @@ "y": 14 }, "id": 7, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "link": false, - "linkTargetBlank": true, - "linkTooltip": "", - "linkUrl": "", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "sanitize": false, - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Calls ", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "short" + "show": false }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "preserveFormat": false, - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "ass", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -470,14 +662,138 @@ } ], "title": "Top queries by calls", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Does not include Shared Buffer activities. Same as 'By total runtime' if no direct IO was performed. Requires track_io_timing=on", - "fontSize": "100%", + "fieldConfig": { + "defaults": { + "custom": { + "align": "auto", + "cellOptions": { + "type": "auto" + }, + "inspect": false + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "displayName", + "value": "Time" + }, + { + "id": "custom.hidden", + "value": true + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "top" + }, + "properties": [ + { + "id": "displayName", + "value": "IO time" + }, + { + "id": "unit", + "value": "ms" + }, + { + "id": "decimals", + "value": 1 + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "queryid" + }, + "properties": [ + { + "id": "displayName", + "value": "Query ID" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "links", + "value": [ + { + "targetBlank": false, + "title": "Opens 'Single query details' dashboard for that queryid", + "url": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to" + } + ] + }, + { + "id": "custom.align" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "query" + }, + "properties": [ + { + "id": "displayName", + "value": "Query" + }, + { + "id": "unit", + "value": "short" + }, + { + "id": "decimals", + "value": 2 + }, + { + "id": "custom.align" + } + ] + } + ] + }, "gridPos": { "h": 7, "w": 24, @@ -485,80 +801,25 @@ "y": 21 }, "id": 8, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "IO time", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "ms" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" + "options": { + "cellHeight": "sm", + "footer": { + "countRows": false, + "fields": "", + "reducer": [ + "sum" ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "thresholds": [], - "type": "string", - "unit": "short" + "show": false }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - } - ], + "showHeader": true + }, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -609,14 +870,18 @@ } ], "title": "Top queries by direct (backend) IO", - "transform": "table", "type": "table" }, { - "columns": [], - "datasource": null, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Shared buffer + temp buffer reading / writing", - "fontSize": "100%", + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, @@ -624,81 +889,13 @@ "y": 28 }, "id": 10, - "links": [], - "pageSize": null, - "scroll": true, - "showHeader": true, - "sort": { - "col": 0, - "desc": true - }, - "styles": [ - { - "alias": "Time", - "align": "auto", - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "pattern": "Time", - "type": "hidden" - }, - { - "alias": "Block bandwith", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "decimals": 1, - "pattern": "top", - "thresholds": [], - "type": "number", - "unit": "decbytes" - }, - { - "alias": "Query ID", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": true, - "linkTargetBlank": true, - "linkTooltip": "Opens 'Single query details' dashboard for that queryid", - "linkUrl": "/d/single-query-details?orgId=1&var-dbname=$dbname&var-queryid=$__cell&from=$__from&to=$__to", - "pattern": "queryid", - "thresholds": [], - "type": "string", - "unit": "short" - }, - { - "alias": "Query", - "align": "auto", - "colorMode": null, - "colors": [ - "rgba(245, 54, 54, 0.9)", - "rgba(237, 129, 40, 0.89)", - "rgba(50, 172, 45, 0.97)" - ], - "dateFormat": "YYYY-MM-DD HH:mm:ss", - "decimals": 2, - "link": false, - "linkTargetBlank": true, - "linkTooltip": "Use 'edit' mode to be able to copy the query text", - "linkUrl": "", - "pattern": "query", - "sanitize": true, - "thresholds": [], - "type": "string", - "unit": "short" - } - ], + "options": {}, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "table", "group": [], "groupBy": [ @@ -749,14 +946,13 @@ } ], "title": "Top by block bandwith (assuming 8K blocks)", - "transform": "table", "type": "table" }, { - "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "datasource": null, - "editable": true, - "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, @@ -764,57 +960,44 @@ "y": 35 }, "id": 4, - "links": [], - "mode": "markdown", + "options": {}, "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 22, - "style": "dark", + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "allValue": null, "current": { - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" + }, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "datasource": null, "definition": "", - "hide": 0, "includeAll": false, - "index": -1, - "label": null, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'stat_statements' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": null, - "tags": [], - "tagsQuery": null, - "type": "query", - "useTags": false + "type": "query" }, { - "allValue": null, "current": { - "tags": [], "text": "5", "value": "5" }, - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "top", "options": [ { @@ -864,20 +1047,14 @@ } ], "query": "1,3,5,10,15,20,30,40,50", - "skipUrlSync": false, "type": "custom" }, { - "allValue": null, "current": { - "tags": [], "text": "yes", "value": "yes" }, - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "hide_pgwatch_generated", "options": [ { @@ -892,7 +1069,6 @@ } ], "query": "yes,no", - "skipUrlSync": false, "type": "custom" } ] @@ -901,33 +1077,9 @@ "from": "now-3h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Stat statements Top", "uid": "stat-statements-top", - "version": 1 + "version": 4 } \ No newline at end of file diff --git a/grafana/postgres/v12/system-stats-time-lag.json b/grafana/postgres/v12/system-stats-time-lag.json index a7b0cd97c..d6e5cc2c7 100644 --- a/grafana/postgres/v12/system-stats-time-lag.json +++ b/grafana/postgres/v12/system-stats-time-lag.json @@ -3,7 +3,10 @@ "list": [ { "builtIn": 1, - "datasource": "-- Grafana --", + "datasource": { + "type": "datasource", + "uid": "grafana" + }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", @@ -13,53 +16,102 @@ ] }, "editable": true, - "gnetId": null, + "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, + "id": 35, "links": [], "panels": [ { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, - "fill": 1, - "fillGradient": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "decimals": 1, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 0 }, - "hiddenSeries": false, "id": 2, - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { - "dataLinks": [] + "dataLinks": [], + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -86,6 +138,10 @@ ] }, { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -112,90 +168,100 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "CPU utilization", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] + "type": "timeseries" + }, + { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "yaxes": [ - { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, "decimals": 1, - "format": "percent", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, - "fill": 1, - "fillGradient": 0, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 7 }, - "hiddenSeries": false, "id": 3, - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { - "dataLinks": [] + "dataLinks": [], + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -222,6 +288,10 @@ ] }, { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -248,91 +318,102 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "IO Wait", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "percent", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "(total - available) / total * 100", - "fill": 1, - "fillGradient": 0, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "decimals": 1, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 14 }, - "hiddenSeries": false, "id": 4, - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { - "dataLinks": [] + "dataLinks": [], + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -359,6 +440,10 @@ ] }, { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -385,90 +470,100 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Memory used (%)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "percent", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": null, - "fill": 1, - "fillGradient": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "bytes" + }, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 21 }, - "hiddenSeries": false, "id": 6, - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { - "dataLinks": [] + "dataLinks": [], + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -495,6 +590,10 @@ ] }, { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -521,89 +620,34 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Memory available", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "bytes", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, - "fill": 1, - "fillGradient": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 28 }, - "hiddenSeries": false, "id": 5, - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { "dataLinks": [] }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -630,6 +674,10 @@ ] }, { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -656,89 +704,34 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Swap used (%)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "percent", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, - "fill": 1, - "fillGradient": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 35 }, - "hiddenSeries": false, "id": 7, - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { "dataLinks": [] }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -765,6 +758,10 @@ ] }, { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "hide": false, @@ -792,89 +789,34 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Total bytes read per second", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "Bps", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, - "fill": 1, - "fillGradient": 0, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 42 }, - "hiddenSeries": false, "id": 9, - "legend": { - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", "options": { "dataLinks": [] }, - "percentage": false, - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, "targets": [ { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "metricColumn": "none", @@ -901,6 +843,10 @@ ] }, { + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "hide": false, @@ -928,88 +874,44 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Total bytes written per second", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "Bps", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" } ], - "schemaVersion": 22, - "style": "dark", + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "allValue": null, - "datasource": null, + "current": { + "text": "demo", + "value": "demo" + }, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric LIKE 'psutil%' ORDER BY 1;", - "hide": 0, "includeAll": false, - "index": -1, - "label": null, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric LIKE 'psutil%' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tags": [], - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "30m", "value": "30m" }, - "hide": 0, - "label": null, "name": "agg_interval", "options": [ { @@ -1060,7 +962,6 @@ ], "query": "1m,5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" }, { @@ -1068,12 +969,9 @@ "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "1d", "value": "1d" }, - "hide": 0, - "label": null, "name": "lag_interval", "options": [ { @@ -1114,7 +1012,6 @@ ], "query": "1h,6h,12h,1d,7d,14d,30d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -1123,25 +1020,9 @@ "from": "now-24h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Systems stats time lag comparison", "uid": "systems-stats-time-lag-comparison", - "variables": { - "list": [] - }, - "version": 1 + "version": 11 } \ No newline at end of file diff --git a/grafana/postgres/v12/system-stats.json b/grafana/postgres/v12/system-stats.json index 75a3928e6..3aa1ce213 100644 --- a/grafana/postgres/v12/system-stats.json +++ b/grafana/postgres/v12/system-stats.json @@ -3,7 +3,10 @@ "list": [ { "builtIn": 1, - "datasource": "-- Grafana --", + "datasource": { + "type": "datasource", + "uid": "grafana" + }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", @@ -14,26 +17,161 @@ }, "description": "Needs according psutil_* helper stored procedures installed on monitored Postgres DBs", "editable": true, - "gnetId": null, + "fiscalYearStartMonth": 0, "graphTooltip": 0, - "id": null, + "id": 14, "links": [], "panels": [ { - "aliasColors": { - "load (1min) normalized to #CPU": "#890f02", - "load 1min norm.": "#bf1b00", - "load_1min_norm": "#bf1b00", - "normalized to #CPU": "#890f02", - "utilization": "#bf1b00" + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, "description": "a.k.a. CPU run queue length or Load Average, reported e.g. by the \"uptime\" command", - "fill": 1, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "decimals": 1, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "none" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "load (1min) normalized to #CPU" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#890f02", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "load 1min norm." + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#bf1b00", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "load_1min_norm" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#bf1b00", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "normalized to #CPU" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#890f02", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "utilization" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#bf1b00", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byRegexp", + "options": "/normalized/" + }, + "properties": [ + { + "id": "custom.lineWidth", + "value": 4 + } + ] + } + ] + }, "gridPos": { "h": 6, "w": 24, @@ -42,36 +180,29 @@ }, "id": 4, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [ - { - "alias": "/normalized/", - "linewidth": 4 + "options": { + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" } - ], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "normalized to #CPU", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -127,61 +258,142 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "System load ($agg_interval avg.)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "none", - "label": "", - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "decimals": null, - "format": "none", - "label": "As reported by /proc/loadavg ", - "logBase": 10, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": { - "load_1min_norm": "#bf1b00", - "utilization": "#bf1b00" + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, "description": "System-wide CPU utilization as reported by psutil.cpu_percent()", - "fill": 1, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "load_1min_norm" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#bf1b00", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "utilization" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#bf1b00", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "load_1min_norm" + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "custom.axisPlacement", + "value": "right" + }, + { + "id": "custom.axisPlacement", + "value": "hidden" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "load 1min norm." + }, + "properties": [ + { + "id": "unit", + "value": "short" + }, + { + "id": "custom.axisPlacement", + "value": "right" + }, + { + "id": "custom.axisPlacement", + "value": "hidden" + } + ] + } + ] + }, "gridPos": { "h": 6, "w": 24, @@ -190,45 +402,29 @@ }, "id": 3, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [ - { - "alias": "utilization", - "yaxis": 1 - }, - { - "alias": "load_1min_norm", - "yaxis": 2 + "options": { + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true }, - { - "alias": "load 1min norm.", - "yaxis": 2 + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" } - ], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + }, + "pluginVersion": "12.0.0", "targets": [ { "alias": "utilization", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -284,55 +480,69 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "CPU utilization % ($agg_interval avg.)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "percent", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": "0", - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, - "fill": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [] + }, "gridPos": { "h": 6, "w": 24, @@ -341,31 +551,29 @@ }, "id": 2, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true + "options": { + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { "alias": "idle", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -423,56 +631,71 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "CPU usage distribution ($agg_interval avg.)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "percent", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Doesn't have to necessarily equal 100% to values reported by the \"free\" command - see [here](https://psutil.readthedocs.io/en/latest/#psutil.virtual_memory) for more", - "fill": 1, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "decimals": 1, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "decbytes" + }, + "overrides": [] + }, "gridPos": { "h": 6, "w": 24, @@ -481,31 +704,29 @@ }, "id": 5, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true + "options": { + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { "alias": "used", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -561,57 +782,71 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Memory usage ($agg_interval avg.)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "decbytes", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "Doesn't have to necessarily equal 100% to values reported by the \"free\" command - see [here](https://psutil.readthedocs.io/en/latest/#psutil.virtual_memory) for more", - "fill": 1, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "decimals": 1, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "decbytes" + }, + "overrides": [] + }, "gridPos": { "h": 6, "w": 24, @@ -620,31 +855,29 @@ }, "id": 6, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true + "options": { + "legend": { + "calcs": [ + "mean" + ], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "desc" + } }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "pluginVersion": "12.0.0", "targets": [ { "alias": "swap_used", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -700,57 +933,19 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Swap usage ($agg_interval avg.)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "decbytes", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "For all disks on the host, not only Postgres related", - "fill": 1, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 6, "w": 24, @@ -759,31 +954,14 @@ }, "id": 11, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "options": {}, "targets": [ { "alias": "read_bytes", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -845,57 +1023,19 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Host disk IO Totals ($agg_interval aggregate)", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "bytes", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "format": "short", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "For Postgres data / WAL / log folder partitions and user defined tablespace partitions", - "fill": 1, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 6, "w": 24, @@ -904,31 +1044,14 @@ }, "id": 7, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "options": {}, "targets": [ { "alias": "[[tag_dir_or_tablespace]] ([[tag_path]])", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -996,58 +1119,19 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Disk usage %", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "percent", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "decimals": 1, - "format": "decbytes", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": null, - "decimals": 1, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "description": "For Postgres data / WAL / log folder partitions and user defined tablespace partitions", - "fill": 1, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 6, "w": 24, @@ -1056,31 +1140,14 @@ }, "id": 8, "interval": "2m", - "legend": { - "alignAsTable": false, - "avg": true, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "percentage": false, - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, + "options": {}, "targets": [ { "alias": "[[tag_dir_or_tablespace]] ([[tag_path]])", + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" + }, "format": "time_series", "group": [], "groupBy": [ @@ -1148,53 +1215,14 @@ ] } ], - "thresholds": [], - "timeFrom": null, - "timeRegions": [], - "timeShift": null, "title": "Disk space available", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "buckets": null, - "mode": "time", - "name": null, - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 1, - "format": "bytes", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": true - }, - { - "decimals": 1, - "format": "decbytes", - "label": null, - "logBase": 1, - "max": null, - "min": null, - "show": false - } - ], - "yaxis": { - "align": false, - "alignLevel": null - } + "type": "timeseries" }, { - "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "editable": true, - "error": false, + "fieldConfig": { + "defaults": {}, + "overrides": [] + }, "gridPos": { "h": 4, "w": 24, @@ -1202,43 +1230,38 @@ "y": 48 }, "id": 10, - "links": [], - "mode": "markdown", + "options": {}, "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 18, - "style": "dark", + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], "templating": { "list": [ { - "allValue": null, "current": { - "text": null + "text": "demo", + "value": "demo" + }, + "datasource": { + "type": "grafana-postgresql-datasource", + "uid": "pgwatch-metrics" }, - "datasource": null, "definition": "", - "hide": 0, "includeAll": false, - "label": null, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric LIKE 'psutil%' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, "sort": 1, - "tagValuesQuery": "", - "tags": [], - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, @@ -1248,8 +1271,6 @@ "text": "10m", "value": "10m" }, - "hide": 0, - "label": null, "name": "agg_interval", "options": [ { @@ -1300,7 +1321,6 @@ ], "query": "1m,5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -1309,33 +1329,9 @@ "from": "now-3h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "", "title": "System Stats", "uid": "system-stats", - "version": 1 + "version": 6 } \ No newline at end of file diff --git a/grafana/postgres/v12/table-details-time-lag.json b/grafana/postgres/v12/table-details-time-lag.json index 38603ed94..0bf2e39b8 100644 --- a/grafana/postgres/v12/table-details-time-lag.json +++ b/grafana/postgres/v12/table-details-time-lag.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 15, "links": [], "panels": [ { @@ -37,6 +38,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -69,8 +71,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -99,11 +100,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -186,6 +188,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -218,8 +221,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -248,11 +250,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -335,6 +338,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -367,8 +371,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -397,11 +400,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -516,8 +520,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -665,8 +668,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -815,8 +817,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -965,8 +966,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1115,8 +1115,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1265,8 +1264,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1415,8 +1413,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1517,7 +1514,9 @@ "type": "timeseries" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1525,33 +1524,24 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics ORDER BY 1;", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { - "selected": false, "text": "pgwatch.metric", "value": "pgwatch.metric" }, @@ -1560,31 +1550,22 @@ "uid": "pgwatch-metrics" }, "definition": "SELECT DISTINCT tag_data->>'table_full_name' FROM table_stats WHERE time > now() - '1d'::interval AND dbname = '$dbname' ORDER BY 1", - "hide": 0, "includeAll": false, - "multi": false, "name": "table_full_name", "options": [], "query": "SELECT DISTINCT tag_data->>'table_full_name' FROM table_stats WHERE time > now() - '1d'::interval AND dbname = '$dbname' ORDER BY 1", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "10m", "value": "10m" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -1655,7 +1636,6 @@ ], "query": "1s,1m,2m,3m,5m,10m,15m,30m,1h,6h,12h,1d,7d", "refresh": 2, - "skipUrlSync": false, "type": "interval" }, { @@ -1663,11 +1643,9 @@ "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "1d", "value": "1d" }, - "hide": 0, "name": "lag_interval", "options": [ { @@ -1708,7 +1686,6 @@ ], "query": "1h,6h,12h,1d,7d,14d,30d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -1717,23 +1694,9 @@ "from": "now-12h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Table details time lag comparison", "uid": "table-details-time-lag", - "version": 1, - "weekStart": "" + "version": 11 } \ No newline at end of file diff --git a/grafana/postgres/v12/table-details.json b/grafana/postgres/v12/table-details.json index 6edae4669..a359a9f95 100644 --- a/grafana/postgres/v12/table-details.json +++ b/grafana/postgres/v12/table-details.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 18, "links": [], "panels": [ { @@ -37,6 +38,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -68,8 +70,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -99,11 +100,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "total_relation_size", @@ -193,6 +195,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -225,8 +228,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -287,11 +289,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "seq_scans", @@ -386,6 +389,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -418,8 +422,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -449,11 +452,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "INS", @@ -548,6 +552,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -580,8 +585,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -611,11 +615,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "Heap", @@ -712,6 +717,7 @@ "axisLabel": "", "axisPlacement": "auto", "barAlignment": 0, + "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, "gradientMode": "none", @@ -742,8 +748,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -773,11 +778,12 @@ "showLegend": true }, "tooltip": { + "hideZeros": false, "mode": "multi", "sort": "desc" } }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "alias": "$tag_index_name", @@ -881,8 +887,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -984,8 +989,7 @@ "mode": "absolute", "steps": [ { - "color": "#299c46", - "value": null + "color": "#299c46" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1062,12 +1066,10 @@ "type": "stat" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, - "editable": true, - "error": false, "gridPos": { "h": 4, "w": 24, @@ -1082,23 +1084,17 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "refId": "A" - } - ], + "title": "", "transparent": true, "type": "text" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1106,31 +1102,25 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'table_stats' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, "sort": 1, - "type": "query", - "useTags": false + "type": "query" }, { "current": { - "selected": false, "text": "pgwatch.metric", "value": "pgwatch.metric" }, @@ -1139,31 +1129,23 @@ "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "table_full_name", "options": [], "query": "SELECT DISTINCT tag_data->>'table_full_name' FROM table_stats WHERE time > current_date-3 AND dbname = '$dbname' ORDER BY 1", "refresh": 1, "regex": "", - "skipUrlSync": false, "sort": 1, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "auto": false, "auto_count": 30, "auto_min": "10s", "current": { - "selected": false, "text": "10m", "value": "10m" }, - "hide": 0, "name": "agg_interval", "options": [ { @@ -1214,7 +1196,6 @@ ], "query": "1m,5m,10m,15m,30m,1h,6h,12h,1d", "refresh": 2, - "skipUrlSync": false, "type": "interval" } ] @@ -1223,34 +1204,9 @@ "from": "now-3h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "browser", "title": "Table details", "uid": "table-details", - "version": 1, - "weekStart": "" + "version": 1 } \ No newline at end of file diff --git a/grafana/postgres/v12/tables-top.json b/grafana/postgres/v12/tables-top.json index 78ac94831..cece9b226 100644 --- a/grafana/postgres/v12/tables-top.json +++ b/grafana/postgres/v12/tables-top.json @@ -18,6 +18,7 @@ "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 0, + "id": 19, "links": [], "panels": [ { @@ -32,6 +33,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -44,8 +46,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -174,7 +175,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -252,6 +253,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -264,8 +266,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -394,7 +395,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -472,6 +473,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -484,8 +486,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -614,7 +615,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -694,6 +695,7 @@ "mode": "thresholds" }, "custom": { + "align": "auto", "cellOptions": { "type": "auto" }, @@ -706,8 +708,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -832,7 +833,7 @@ }, "showHeader": true }, - "pluginVersion": "10.4.1", + "pluginVersion": "12.0.0", "targets": [ { "datasource": { @@ -923,8 +924,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1145,8 +1145,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1367,8 +1366,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1588,8 +1586,7 @@ "mode": "absolute", "steps": [ { - "color": "green", - "value": null + "color": "green" }, { "color": "red", @@ -1820,9 +1817,9 @@ "type": "table" }, { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" + "fieldConfig": { + "defaults": {}, + "overrides": [] }, "gridPos": { "h": 4, @@ -1838,41 +1835,10 @@ "showMiniMap": false }, "content": "### Brought to you by\n\n[![Cybertec – The PostgreSQL Database Company](https://www.cybertec-postgresql.com/wp-content/uploads/2025/02/cybertec-logo-white-blue.svg)](https://www.cybertec-postgresql.com/en/)\n", - "mode": "markdown" + "mode": "markdown" }, "pluginVersion": "10.4.1", - "targets": [ - { - "datasource": { - "type": "grafana-postgresql-datasource", - "uid": "pgwatch-metrics" - }, - "format": "time_series", - "group": [], - "metricColumn": "none", - "rawQuery": false, - "rawSql": "SELECT\n $__time(time_column),\n value1\nFROM\n metric_table\nWHERE\n $__timeFilter(time_column)\n", - "refId": "A", - "select": [ - [ - { - "params": [ - "value" - ], - "type": "column" - } - ] - ], - "timeColumn": "time", - "where": [ - { - "name": "$__timeFilter", - "params": [], - "type": "macro" - } - ] - } - ], + "title": "", "transparent": true, "type": "text" }, @@ -1912,8 +1878,7 @@ "mode": "absolute", "steps": [ { - "color": "#56A64B", - "value": null + "color": "#56A64B" }, { "color": "rgba(237, 129, 40, 0.89)", @@ -1986,11 +1951,14 @@ ] } ], + "title": "", "transparent": true, "type": "stat" } ], - "schemaVersion": 39, + "preload": false, + "refresh": "", + "schemaVersion": 41, "tags": [ "pgwatch" ], @@ -1998,39 +1966,28 @@ "list": [ { "current": { - "selected": false, - "text": "test", - "value": "test" + "text": "demo", + "value": "demo" }, "datasource": { "type": "grafana-postgresql-datasource", "uid": "pgwatch-metrics" }, "definition": "", - "hide": 0, "includeAll": false, - "multi": false, "name": "dbname", "options": [], "query": "SELECT DISTINCT dbname FROM admin.all_distinct_dbname_metrics WHERE metric = 'table_stats' ORDER BY 1;", "refresh": 1, "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false + "type": "query" }, { "current": { - "selected": false, "text": "5", "value": "5" }, - "hide": 0, "includeAll": false, - "multi": false, "name": "top", "options": [ { @@ -2065,7 +2022,6 @@ } ], "query": "1,3,5,10,20,50", - "skipUrlSync": false, "type": "custom" } ] @@ -2074,34 +2030,9 @@ "from": "now-6h", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, + "timepicker": {}, "timezone": "", "title": "Tables Top", "uid": "tables-top", - "version": 1, - "weekStart": "" + "version": 6 } \ No newline at end of file