From 9f9b00a6fb47d22060409dca6d47c8a00c50bb47 Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Mon, 13 Apr 2026 06:24:35 -0300 Subject: [PATCH] monitoring(jenkins): switch weather to single stat-list panel --- scripts/dashboards_render_atlas.py | 216 +++--- .../monitoring/dashboards/atlas-jobs.json | 373 +--------- .../monitoring/dashboards/atlas-overview.json | 685 ++++-------------- .../monitoring/grafana-dashboard-jobs.yaml | 373 +--------- .../grafana-dashboard-overview.yaml | 685 ++++-------------- 5 files changed, 461 insertions(+), 1871 deletions(-) diff --git a/scripts/dashboards_render_atlas.py b/scripts/dashboards_render_atlas.py index 367e28f2..06ce254a 100644 --- a/scripts/dashboards_render_atlas.py +++ b/scripts/dashboards_render_atlas.py @@ -1499,6 +1499,103 @@ def jenkins_weather_bargauge_panel( return panel +def jenkins_weather_statlist_panel( + panel_id, + title, + expr, + grid, + *, + unit="h", + decimals=2, + sort_order="asc", + limit=12, + links=None, + description=None, +): + panel = { + "id": panel_id, + "type": "stat", + "title": title, + "datasource": PROM_DS, + "gridPos": grid, + "targets": [ + { + "refId": "A", + "expr": _jenkins_weather_status_expr(expr, "== 1"), + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": True, + }, + { + "refId": "B", + "expr": _jenkins_weather_status_expr(expr, "== 0"), + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": True, + }, + { + "refId": "C", + "expr": _jenkins_weather_status_expr(expr, "== 2"), + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": True, + }, + { + "refId": "D", + "expr": _jenkins_weather_status_expr(expr, "< 0"), + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": True, + }, + ], + "fieldConfig": { + "defaults": { + "unit": unit, + "decimals": decimals, + "min": 0, + "links": [ + { + "title": "Open Jenkins job", + "url": "${__field.labels.job_url}", + "targetBlank": True, + } + ], + }, + "overrides": [ + { + "matcher": {"id": "byFrameRefID", "options": "A"}, + "properties": [{"id": "color", "value": {"mode": "fixed", "fixedColor": "green"}}], + }, + { + "matcher": {"id": "byFrameRefID", "options": "B"}, + "properties": [{"id": "color", "value": {"mode": "fixed", "fixedColor": "red"}}], + }, + { + "matcher": {"id": "byFrameRefID", "options": "C"}, + "properties": [{"id": "color", "value": {"mode": "fixed", "fixedColor": "yellow"}}], + }, + { + "matcher": {"id": "byFrameRefID", "options": "D"}, + "properties": [{"id": "color", "value": {"mode": "fixed", "fixedColor": "gray"}}], + }, + ], + }, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "wideLayout": True, + "reduceOptions": {"calcs": ["lastNotNull"], "fields": "", "values": False}, + "textMode": "name_value", + }, + "transformations": [{"id": "sortBy", "options": {"fields": ["Value"], "order": sort_order}}], + } + if limit: + panel["transformations"].append({"id": "limit", "options": {"limit": limit}}) + if links: + panel["links"] = links + if description: + panel["description"] = description + return panel + + def text_panel(panel_id, title, content, grid): return { "id": panel_id, @@ -2074,12 +2171,29 @@ def build_overview(): "Per-run interval pass points (0-100) for each software suite over the last 7 days. Points are connected to show trend; missing-run intervals are ignored." ) panels.append(test_success) + panels.append( + jenkins_weather_statlist_panel( + 142, + "Jenkins Build Weather (last run h, newest first)", + JENKINS_BUILD_WEATHER_LAST_RUN_AGE_HOURS, + {"h": 5, "w": 8, "x": 8, "y": 32}, + unit="h", + decimals=2, + sort_order="asc", + limit=8, + links=link_to("atlas-jobs"), + description=( + "Jenkins homepage-style list from Ariadne with weather icons and status-colored job names. " + "Click a name to open the Jenkins job page." + ), + ) + ) panels.append( bargauge_panel( 47, "PVC Backup Health / Age", PVC_BACKUP_AGE_HOURS_BY_PVC, - {"h": 5, "w": 24, "x": 0, "y": 56}, + {"h": 5, "w": 8, "x": 16, "y": 32}, unit="h", instant=True, legend="{{namespace}}/{{pvc}}", @@ -2100,61 +2214,6 @@ def build_overview(): "Backup age in hours computed from last-success timestamps for restic-managed PVCs. " "PVCs that have backup history but currently no successful backup (missing/no_completed/error) are pinned to 999h for visibility." ) - panels.append( - jenkins_weather_bargauge_panel( - 142, - "Jenkins Last Run (hours ago, newest first)", - JENKINS_BUILD_WEATHER_LAST_RUN_AGE_HOURS, - {"h": 5, "w": 5, "x": 8, "y": 32}, - unit="h", - decimals=2, - sort_order="asc", - limit=8, - thresholds=age_thresholds, - links=link_to("atlas-jobs"), - description=( - "Jenkins weather list from Ariadne: icon + name with status color and age since the most recent run." - ), - ) - ) - panels.append( - jenkins_weather_bargauge_panel( - 243, - "Jenkins Last Success (hours ago)", - JENKINS_BUILD_WEATHER_LAST_SUCCESS_AGE_HOURS, - {"h": 5, "w": 5, "x": 13, "y": 32}, - unit="h", - decimals=2, - sort_order="asc", - limit=8, - thresholds=age_thresholds, - links=link_to("atlas-jobs"), - description="Per-job age since the most recent successful run.", - ) - ) - panels.append( - jenkins_weather_bargauge_panel( - 244, - "Jenkins Last Duration (minutes)", - JENKINS_BUILD_WEATHER_LAST_DURATION_MINUTES, - {"h": 5, "w": 6, "x": 18, "y": 32}, - unit="m", - decimals=2, - sort_order="desc", - limit=8, - thresholds={ - "mode": "absolute", - "steps": [ - {"color": "green", "value": None}, - {"color": "yellow", "value": 5}, - {"color": "orange", "value": 15}, - {"color": "red", "value": 30}, - ], - }, - links=link_to("atlas-jobs"), - description="Most recent completed build duration per Jenkins job.", - ) - ) panels.append( stat_panel( @@ -3766,58 +3825,21 @@ def build_jobs_dashboard(): ) ) panels.append( - jenkins_weather_bargauge_panel( + jenkins_weather_statlist_panel( 24, "Jenkins Build Weather (last run h, newest first)", JENKINS_BUILD_WEATHER_LAST_RUN_AGE_HOURS, - {"h": 8, "w": 8, "x": 0, "y": 44}, + {"h": 8, "w": 24, "x": 0, "y": 44}, unit="h", decimals=2, sort_order="asc", limit=20, - thresholds=age_thresholds, description=( - "Jenkins homepage-style weather list: bars are color-coded by last build " - "status, icons mirror job weather, and values show age since the last run." + "Jenkins homepage-style list from Ariadne with weather icons and status-colored job names. " + "Click a name to open the Jenkins job page." ), ) ) - panels.append( - jenkins_weather_bargauge_panel( - 25, - "Jenkins Last Success (hours ago)", - JENKINS_BUILD_WEATHER_LAST_SUCCESS_AGE_HOURS, - {"h": 8, "w": 8, "x": 8, "y": 44}, - unit="h", - decimals=2, - sort_order="asc", - limit=20, - thresholds=old_age_thresholds, - description="Per-job age since the most recent successful run.", - ) - ) - panels.append( - jenkins_weather_bargauge_panel( - 26, - "Jenkins Last Duration (minutes)", - JENKINS_BUILD_WEATHER_LAST_DURATION_MINUTES, - {"h": 8, "w": 8, "x": 16, "y": 44}, - unit="m", - decimals=2, - sort_order="desc", - limit=20, - thresholds={ - "mode": "absolute", - "steps": [ - {"color": "green", "value": None}, - {"color": "yellow", "value": 5}, - {"color": "orange", "value": 15}, - {"color": "red", "value": 30}, - ], - }, - description="Most recent completed build duration per Jenkins job.", - ) - ) stale_volume_panel = bargauge_panel( 27, "Jenkins Workspace PV Age (h, detached only)", diff --git a/services/monitoring/dashboards/atlas-jobs.json b/services/monitoring/dashboards/atlas-jobs.json index 8d571996..75341ca7 100644 --- a/services/monitoring/dashboards/atlas-jobs.json +++ b/services/monitoring/dashboards/atlas-jobs.json @@ -1536,7 +1536,7 @@ }, { "id": 24, - "type": "bargauge", + "type": "stat", "title": "Jenkins Build Weather (last run h, newest first)", "datasource": { "type": "prometheus", @@ -1544,7 +1544,7 @@ }, "gridPos": { "h": 8, - "w": 8, + "w": 24, "x": 0, "y": 44 }, @@ -1577,36 +1577,15 @@ "fieldConfig": { "defaults": { "unit": "h", + "decimals": 2, "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 6 - }, - { - "color": "orange", - "value": 24 - }, - { - "color": "red", - "value": 48 - } - ] - }, "links": [ { "title": "Open Jenkins job", "url": "${__field.labels.job_url}", "targetBlank": true } - ], - "decimals": 2 + ] }, "overrides": [ { @@ -1672,15 +1651,19 @@ ] }, "options": { - "displayMode": "basic", + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", "orientation": "horizontal", + "wideLayout": true, "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false - } + }, + "textMode": "name_value" }, "transformations": [ { @@ -1699,341 +1682,7 @@ } } ], - "description": "Jenkins homepage-style weather list: bars are color-coded by last build status, icons mirror job weather, and values show age since the last run." - }, - { - "id": 25, - "type": "bargauge", - "title": "Jenkins Last Success (hours ago)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 8, - "w": 8, - "x": 8, - "y": 44 - }, - "targets": [ - { - "refId": "A", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "h", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 24 - }, - { - "color": "orange", - "value": 72 - }, - { - "color": "red", - "value": 168 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "asc" - } - }, - { - "id": "limit", - "options": { - "limit": 20 - } - } - ], - "description": "Per-job age since the most recent successful run." - }, - { - "id": 26, - "type": "bargauge", - "title": "Jenkins Last Duration (minutes)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 8, - "w": 8, - "x": 16, - "y": 44 - }, - "targets": [ - { - "refId": "A", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "m", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 5 - }, - { - "color": "orange", - "value": 15 - }, - { - "color": "red", - "value": 30 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "desc" - } - }, - { - "id": "limit", - "options": { - "limit": 20 - } - } - ], - "description": "Most recent completed build duration per Jenkins job." + "description": "Jenkins homepage-style list from Ariadne with weather icons and status-colored job names. Click a name to open the Jenkins job page." }, { "id": 27, diff --git a/services/monitoring/dashboards/atlas-overview.json b/services/monitoring/dashboards/atlas-overview.json index 191714e5..24e46955 100644 --- a/services/monitoring/dashboards/atlas-overview.json +++ b/services/monitoring/dashboards/atlas-overview.json @@ -2270,6 +2270,163 @@ "timeFrom": "7d", "description": "Per-run interval pass points (0-100) for each software suite over the last 7 days. Points are connected to show trend; missing-run intervals are ignored." }, + { + "id": 142, + "type": "stat", + "title": "Jenkins Build Weather (last run h, newest first)", + "datasource": { + "type": "prometheus", + "uid": "atlas-vm" + }, + "gridPos": { + "h": 5, + "w": 8, + "x": 8, + "y": 32 + }, + "targets": [ + { + "refId": "A", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + }, + { + "refId": "B", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + }, + { + "refId": "C", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + }, + { + "refId": "D", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + } + ], + "fieldConfig": { + "defaults": { + "unit": "h", + "decimals": 2, + "min": 0, + "links": [ + { + "title": "Open Jenkins job", + "url": "${__field.labels.job_url}", + "targetBlank": true + } + ] + }, + "overrides": [ + { + "matcher": { + "id": "byFrameRefID", + "options": "A" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "green" + } + } + ] + }, + { + "matcher": { + "id": "byFrameRefID", + "options": "B" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "red" + } + } + ] + }, + { + "matcher": { + "id": "byFrameRefID", + "options": "C" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "yellow" + } + } + ] + }, + { + "matcher": { + "id": "byFrameRefID", + "options": "D" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "gray" + } + } + ] + } + ] + }, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "wideLayout": true, + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "name_value" + }, + "transformations": [ + { + "id": "sortBy", + "options": { + "fields": [ + "Value" + ], + "order": "asc" + } + }, + { + "id": "limit", + "options": { + "limit": 8 + } + } + ], + "links": [ + { + "title": "Open atlas-jobs dashboard", + "url": "/d/atlas-jobs", + "targetBlank": true + } + ], + "description": "Jenkins homepage-style list from Ariadne with weather icons and status-colored job names. Click a name to open the Jenkins job page." + }, { "id": 47, "type": "bargauge", @@ -2280,9 +2437,9 @@ }, "gridPos": { "h": 5, - "w": 24, - "x": 0, - "y": 56 + "w": 8, + "x": 16, + "y": 32 }, "targets": [ { @@ -2352,528 +2509,6 @@ ], "description": "Backup age in hours computed from last-success timestamps for restic-managed PVCs. PVCs that have backup history but currently no successful backup (missing/no_completed/error) are pinned to 999h for visibility." }, - { - "id": 142, - "type": "bargauge", - "title": "Jenkins Last Run (hours ago, newest first)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 5, - "w": 5, - "x": 8, - "y": 32 - }, - "targets": [ - { - "refId": "A", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "h", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 6 - }, - { - "color": "orange", - "value": 24 - }, - { - "color": "red", - "value": 48 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "asc" - } - }, - { - "id": "limit", - "options": { - "limit": 8 - } - } - ], - "links": [ - { - "title": "Open atlas-jobs dashboard", - "url": "/d/atlas-jobs", - "targetBlank": true - } - ], - "description": "Jenkins weather list from Ariadne: icon + name with status color and age since the most recent run." - }, - { - "id": 243, - "type": "bargauge", - "title": "Jenkins Last Success (hours ago)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 5, - "w": 5, - "x": 13, - "y": 32 - }, - "targets": [ - { - "refId": "A", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "h", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 6 - }, - { - "color": "orange", - "value": 24 - }, - { - "color": "red", - "value": 48 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "asc" - } - }, - { - "id": "limit", - "options": { - "limit": 8 - } - } - ], - "links": [ - { - "title": "Open atlas-jobs dashboard", - "url": "/d/atlas-jobs", - "targetBlank": true - } - ], - "description": "Per-job age since the most recent successful run." - }, - { - "id": 244, - "type": "bargauge", - "title": "Jenkins Last Duration (minutes)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 32 - }, - "targets": [ - { - "refId": "A", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "m", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 5 - }, - { - "color": "orange", - "value": 15 - }, - { - "color": "red", - "value": 30 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "desc" - } - }, - { - "id": "limit", - "options": { - "limit": 8 - } - } - ], - "links": [ - { - "title": "Open atlas-jobs dashboard", - "url": "/d/atlas-jobs", - "targetBlank": true - } - ], - "description": "Most recent completed build duration per Jenkins job." - }, { "id": 30, "type": "stat", diff --git a/services/monitoring/grafana-dashboard-jobs.yaml b/services/monitoring/grafana-dashboard-jobs.yaml index 00f45859..ee8a8035 100644 --- a/services/monitoring/grafana-dashboard-jobs.yaml +++ b/services/monitoring/grafana-dashboard-jobs.yaml @@ -1545,7 +1545,7 @@ data: }, { "id": 24, - "type": "bargauge", + "type": "stat", "title": "Jenkins Build Weather (last run h, newest first)", "datasource": { "type": "prometheus", @@ -1553,7 +1553,7 @@ data: }, "gridPos": { "h": 8, - "w": 8, + "w": 24, "x": 0, "y": 44 }, @@ -1586,36 +1586,15 @@ data: "fieldConfig": { "defaults": { "unit": "h", + "decimals": 2, "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 6 - }, - { - "color": "orange", - "value": 24 - }, - { - "color": "red", - "value": 48 - } - ] - }, "links": [ { "title": "Open Jenkins job", "url": "${__field.labels.job_url}", "targetBlank": true } - ], - "decimals": 2 + ] }, "overrides": [ { @@ -1681,15 +1660,19 @@ data: ] }, "options": { - "displayMode": "basic", + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", "orientation": "horizontal", + "wideLayout": true, "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false - } + }, + "textMode": "name_value" }, "transformations": [ { @@ -1708,341 +1691,7 @@ data: } } ], - "description": "Jenkins homepage-style weather list: bars are color-coded by last build status, icons mirror job weather, and values show age since the last run." - }, - { - "id": 25, - "type": "bargauge", - "title": "Jenkins Last Success (hours ago)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 8, - "w": 8, - "x": 8, - "y": 44 - }, - "targets": [ - { - "refId": "A", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "h", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 24 - }, - { - "color": "orange", - "value": 72 - }, - { - "color": "red", - "value": 168 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "asc" - } - }, - { - "id": "limit", - "options": { - "limit": 20 - } - } - ], - "description": "Per-job age since the most recent successful run." - }, - { - "id": 26, - "type": "bargauge", - "title": "Jenkins Last Duration (minutes)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 8, - "w": 8, - "x": 16, - "y": 44 - }, - "targets": [ - { - "refId": "A", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "m", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 5 - }, - { - "color": "orange", - "value": 15 - }, - { - "color": "red", - "value": 30 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "desc" - } - }, - { - "id": "limit", - "options": { - "limit": 20 - } - } - ], - "description": "Most recent completed build duration per Jenkins job." + "description": "Jenkins homepage-style list from Ariadne with weather icons and status-colored job names. Click a name to open the Jenkins job page." }, { "id": 27, diff --git a/services/monitoring/grafana-dashboard-overview.yaml b/services/monitoring/grafana-dashboard-overview.yaml index 5a416496..946bbea2 100644 --- a/services/monitoring/grafana-dashboard-overview.yaml +++ b/services/monitoring/grafana-dashboard-overview.yaml @@ -2279,6 +2279,163 @@ data: "timeFrom": "7d", "description": "Per-run interval pass points (0-100) for each software suite over the last 7 days. Points are connected to show trend; missing-run intervals are ignored." }, + { + "id": 142, + "type": "stat", + "title": "Jenkins Build Weather (last run h, newest first)", + "datasource": { + "type": "prometheus", + "uid": "atlas-vm" + }, + "gridPos": { + "h": 5, + "w": 8, + "x": 8, + "y": 32 + }, + "targets": [ + { + "refId": "A", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + }, + { + "refId": "B", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + }, + { + "refId": "C", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + }, + { + "refId": "D", + "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", + "legendFormat": "{{weather_icon}} {{exported_job}}", + "instant": true + } + ], + "fieldConfig": { + "defaults": { + "unit": "h", + "decimals": 2, + "min": 0, + "links": [ + { + "title": "Open Jenkins job", + "url": "${__field.labels.job_url}", + "targetBlank": true + } + ] + }, + "overrides": [ + { + "matcher": { + "id": "byFrameRefID", + "options": "A" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "green" + } + } + ] + }, + { + "matcher": { + "id": "byFrameRefID", + "options": "B" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "red" + } + } + ] + }, + { + "matcher": { + "id": "byFrameRefID", + "options": "C" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "yellow" + } + } + ] + }, + { + "matcher": { + "id": "byFrameRefID", + "options": "D" + }, + "properties": [ + { + "id": "color", + "value": { + "mode": "fixed", + "fixedColor": "gray" + } + } + ] + } + ] + }, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "wideLayout": true, + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "name_value" + }, + "transformations": [ + { + "id": "sortBy", + "options": { + "fields": [ + "Value" + ], + "order": "asc" + } + }, + { + "id": "limit", + "options": { + "limit": 8 + } + } + ], + "links": [ + { + "title": "Open atlas-jobs dashboard", + "url": "/d/atlas-jobs", + "targetBlank": true + } + ], + "description": "Jenkins homepage-style list from Ariadne with weather icons and status-colored job names. Click a name to open the Jenkins job page." + }, { "id": 47, "type": "bargauge", @@ -2289,9 +2446,9 @@ data: }, "gridPos": { "h": 5, - "w": 24, - "x": 0, - "y": 56 + "w": 8, + "x": 16, + "y": 32 }, "targets": [ { @@ -2361,528 +2518,6 @@ data: ], "description": "Backup age in hours computed from last-success timestamps for restic-managed PVCs. PVCs that have backup history but currently no successful backup (missing/no_completed/error) are pinned to 999h for visibility." }, - { - "id": 142, - "type": "bargauge", - "title": "Jenkins Last Run (hours ago, newest first)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 5, - "w": 5, - "x": 8, - "y": 32 - }, - "targets": [ - { - "refId": "A", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_run_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "h", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 6 - }, - { - "color": "orange", - "value": 24 - }, - { - "color": "red", - "value": 48 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "asc" - } - }, - { - "id": "limit", - "options": { - "limit": 8 - } - } - ], - "links": [ - { - "title": "Open atlas-jobs dashboard", - "url": "/d/atlas-jobs", - "targetBlank": true - } - ], - "description": "Jenkins weather list from Ariadne: icon + name with status color and age since the most recent run." - }, - { - "id": 243, - "type": "bargauge", - "title": "Jenkins Last Success (hours ago)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 5, - "w": 5, - "x": 13, - "y": 32 - }, - "targets": [ - { - "refId": "A", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "((time() - ariadne_jenkins_build_weather_job_last_success_timestamp_seconds) / 3600) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "h", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 6 - }, - { - "color": "orange", - "value": 24 - }, - { - "color": "red", - "value": 48 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "asc" - } - }, - { - "id": "limit", - "options": { - "limit": 8 - } - } - ], - "links": [ - { - "title": "Open atlas-jobs dashboard", - "url": "/d/atlas-jobs", - "targetBlank": true - } - ], - "description": "Per-job age since the most recent successful run." - }, - { - "id": 244, - "type": "bargauge", - "title": "Jenkins Last Duration (minutes)", - "datasource": { - "type": "prometheus", - "uid": "atlas-vm" - }, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 32 - }, - "targets": [ - { - "refId": "A", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 1)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "B", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "C", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status == 2)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - }, - { - "refId": "D", - "expr": "(ariadne_jenkins_build_weather_job_last_duration_seconds / 60) and on(exported_job,job_url,weather_icon) (ariadne_jenkins_build_weather_job_last_status < 0)", - "legendFormat": "{{weather_icon}} {{exported_job}}", - "instant": true - } - ], - "fieldConfig": { - "defaults": { - "unit": "m", - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 5 - }, - { - "color": "orange", - "value": 15 - }, - { - "color": "red", - "value": 30 - } - ] - }, - "links": [ - { - "title": "Open Jenkins job", - "url": "${__field.labels.job_url}", - "targetBlank": true - } - ], - "decimals": 2 - }, - "overrides": [ - { - "matcher": { - "id": "byFrameRefID", - "options": "A" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "green" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "B" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "red" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "C" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "yellow" - } - } - ] - }, - { - "matcher": { - "id": "byFrameRefID", - "options": "D" - }, - "properties": [ - { - "id": "color", - "value": { - "mode": "fixed", - "fixedColor": "gray" - } - } - ] - } - ] - }, - "options": { - "displayMode": "basic", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - } - }, - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": [ - "Value" - ], - "order": "desc" - } - }, - { - "id": "limit", - "options": { - "limit": 8 - } - } - ], - "links": [ - { - "title": "Open atlas-jobs dashboard", - "url": "/d/atlas-jobs", - "targetBlank": true - } - ], - "description": "Most recent completed build duration per Jenkins job." - }, { "id": 30, "type": "stat",