From 5241c92d5212e9e14000393c35ac8d8def7466ab Mon Sep 17 00:00:00 2001 From: Adam Saleh Date: Oct 19 2020 20:22:54 +0000 Subject: Added preset dashboards and a route. --- diff --git a/playbooks/openshift-apps/monitor_dashboard.yml b/playbooks/openshift-apps/monitor_dashboard.yml index 225989e..3fc9c68 100644 --- a/playbooks/openshift-apps/monitor_dashboard.yml +++ b/playbooks/openshift-apps/monitor_dashboard.yml @@ -27,5 +27,25 @@ - role: openshift/object app: monitor-dashboard + template: dashboard_provision_config.yml + objectname: dashboard_provision_config.yml + + - role: openshift/object + app: monitor-dashboard + template: dashboard_config.yml + objectname: dashboard_config.yml + + - role: openshift/object + app: monitor-dashboard + file: service.yml + objectname: service.yml + + - role: openshift/object + app: monitor-dashboard + file: route.yml + objectname: route.yml + + - role: openshift/object + app: monitor-dashboard template: deploymentconfig.yml objectname: deploymentconfig.yml diff --git a/roles/openshift-apps/monitor-dashboard/files/dashboard_anitya.json b/roles/openshift-apps/monitor-dashboard/files/dashboard_anitya.json new file mode 100644 index 0000000..8901260 --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/dashboard_anitya.json @@ -0,0 +1,282 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "editable": true, + "gnetId": null, + "graphTooltip": 0, + "id": 2, + "links": [], + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "description": "", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 0 + }, + "hiddenSeries": false, + "id": 6, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.2.1", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "SELECT\n date(\"timestamp\") AS time,\n count(*)\nFROM\n messages\nWHERE\n topic like '%project.add%' AND\n $__timeFilter(\"timestamp\")\ngroup by\n time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "New projects per day", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 8 + }, + "hiddenSeries": false, + "id": 4, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "options": { + "alertThreshold": true + }, + "percentage": false, + "pluginVersion": "7.2.1", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "SELECT\n date(\"timestamp\") AS time,\n count(*)\nFROM\n messages\nWHERE\n topic like '%version.update%' AND\n $__timeFilter(\"timestamp\")\ngroup by\n time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Updates per day", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + } + ], + "schemaVersion": 26, + "style": "dark", + "tags": [], + "templating": { + "list": [] + }, + "time": { + "from": "now-7d", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Anitya", + "uid": "8Zi9LU5Mz", + "version": 5 + } \ No newline at end of file diff --git a/roles/openshift-apps/monitor-dashboard/files/dashboard_config.yml b/roles/openshift-apps/monitor-dashboard/files/dashboard_config.yml new file mode 100644 index 0000000..d666bc9 --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/dashboard_config.yml @@ -0,0 +1,12 @@ +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: grafana-dashboards + labels: + app: monitor-dashboard +data: + dashboard_monitor_gating.json: + {{ load_file('dashboard_monitor_gating.json') | indent }} + dashboard_anitya.json: + {{ load_file('dashboard_anitya.json') | indent }} diff --git a/roles/openshift-apps/monitor-dashboard/files/dashboard_monitor_gating.json b/roles/openshift-apps/monitor-dashboard/files/dashboard_monitor_gating.json new file mode 100644 index 0000000..5690ec7 --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/dashboard_monitor_gating.json @@ -0,0 +1,2878 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "editable": true, + "gnetId": null, + "graphTooltip": 0, + "id": 1, + "iteration": 1601285697167, + "links": [], + "panels": [ + { + "datasource": null, + "description": "", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "gridPos": { + "h": 5, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 39, + "options": { + "content": "# Monitor-gating analysis\n\nAnalysis of runs of the https://pagure.io/fedora-ci/monitor-gating project over time.\n\nNotes on triaging problems here: https://hackmd.io/3NWpzzutTDu8CXFrIT1JqQ?both ", + "mode": "markdown" + }, + "pluginVersion": "7.1.0", + "targets": [ + { + "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" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Monitor-gating analysis", + "type": "text" + }, + { + "datasource": null, + "description": "Percentage of successful runs (as noted by monitor-gating sending org.fedoraproject.prod.monitor-gating.$test.end.success message) out of all of org.fedoraproject.prod.monitor-gating.$test.end.* messages ", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "max": 100, + "min": 0, + "thresholds": { + "mode": "percentage", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 0, + "y": 5 + }, + "id": 8, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where $__timeFilter(c.time) and c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Full Run Success in %", + "type": "gauge" + }, + { + "datasource": null, + "description": "Percentage of runs that reached the step in the build where the package was successfully cloned, its version was bumped and it was pushed again.", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "max": 100, + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 3, + "y": 5 + }, + "id": 9, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' ~ '.*Pushing changes\\s+\\[DONE\\]') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where $__timeFilter(c.time) and c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Pagure Success in %", + "type": "gauge" + }, + { + "datasource": null, + "description": "Percentage of runs that reached the step of Koji successfully finishing the package build.", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 6, + "y": 5 + }, + "id": 11, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' ~ '.*uilding the package.+\\[DONE\\]') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Koji Success in %", + "type": "gauge" + }, + { + "datasource": null, + "description": "Percentage of runs that successfuly reached the step of initial creation of the update in Bodhi", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "max": 100, + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 9, + "y": 5 + }, + "id": 10, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' ~ 'bodhi[^\\n]+\\[DONE\\]') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where $__timeFilter(c.time) and c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Bodhi Success in %", + "type": "gauge" + }, + { + "datasource": null, + "description": "Percentage of runs, where it reached the notification for the test failing in CI in a given time-limit.", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "max": 100, + "min": 0, + "thresholds": { + "mode": "percentage", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 12, + "y": 5 + }, + "id": 7, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' LIKE '%CI (complete) results in datagrepper returned error%') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where $__timeFilter(c.time) and c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "CI Fast & Correct in %", + "type": "gauge" + }, + { + "datasource": null, + "description": "Percentage of runs where resultsdb send out the notification for learning about the result in the given time-limit.", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "max": 100, + "min": 0, + "thresholds": { + "mode": "percentage", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 15, + "y": 5 + }, + "id": 14, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' ~ 'resultsdb results in datagrepper returned FAILED[^\\n]+\\[DONE\\]') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where $__timeFilter(c.time) and c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "ResultsDB Fast & Correct in %", + "type": "gauge" + }, + { + "datasource": null, + "description": "Percentage of runs that reached the Greenwave gating a release of a backage based on a failed CI run", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "max": 100, + "min": 0, + "thresholds": { + "mode": "percentage", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 18, + "y": 5 + }, + "id": 12, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' ~ 'greenwave results in datagrepper returned False[^\\n]+\\[DONE\\]') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where $__timeFilter(c.time) and c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Greenwave Fast & Correct in %", + "type": "gauge" + }, + { + "datasource": null, + "description": "Percentage of runs successfully waived", + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "max": 100, + "min": 0, + "thresholds": { + "mode": "percentage", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "green", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 3, + "x": 21, + "y": 5 + }, + "id": 13, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "/^percent_ci_done$/", + "values": false + }, + "showThresholdLabels": true, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' ~ 'greenwave results in datagrepper returned True[^\\n]+\\[DONE\\]') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where $__timeFilter(c.time) and c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Waiverdb Fast & Correct in %", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 20 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 3, + "x": 0, + "y": 12 + }, + "id": 17, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \"timestamp\" as time, CAST(array_to_string(REGEXP_MATCHES(_msg::jsonb->'output'->>-1, 'Ran for (\\d+).*'),'') as integer)/60 from messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median run in minutes", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 3, + "x": 6, + "y": 12 + }, + "id": 37, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \r\n \"timestamp\" as time,\r\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*updates-candidate.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \r\n - \r\n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*uilding the package.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\r\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median build in minutes", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 3, + "x": 12, + "y": 12 + }, + "id": 26, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*running.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*bodhi to CI.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median queue in minutes", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 3, + "x": 15, + "y": 12 + }, + "id": 30, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*resultsdb results in datagrepper returned FAILED[^\\n]+\\[.*D.*\\]\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*complete.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) AND topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median to resultsdb", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 3, + "x": 18, + "y": 12 + }, + "id": 29, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*greenwave results in datagrepper returned False.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*resultsdb results in datagrepper returned FAILED[^\\n]+\\[.*D.*\\]\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) AND topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median from resultsbd to greenwave", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 3, + "x": 21, + "y": 12 + }, + "id": 28, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*greenwave results in datagrepper returned True.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*greenwave results in datagrepper returned False.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) AND topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median from unwaived to waived", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 5, + "w": 3, + "x": 6, + "y": 16 + }, + "id": 25, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n timestamp as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*testing-.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*updates-candidate.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median signing in minutes", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 3, + "x": 12, + "y": 16 + }, + "id": 27, + "options": { + "reduceOptions": { + "calcs": [ + "mean" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*complete.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*running.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Median testing in minutes", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {}, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 20 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 3, + "x": 0, + "y": 20 + }, + "id": 31, + "options": { + "reduceOptions": { + "calcs": [ + "max" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \"timestamp\" as time, CAST(array_to_string(REGEXP_MATCHES(_msg::jsonb->'output'->>-1, 'Ran for (\\d+).*'),'') as integer)/60 from messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Max run in minutes", + "type": "gauge" + }, + { + "datasource": null, + "description": "", + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 10 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 3, + "x": 12, + "y": 20 + }, + "id": 34, + "options": { + "reduceOptions": { + "calcs": [ + "max" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*running.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*bodhi to CI.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Max queue in minutes", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 10 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 3, + "x": 15, + "y": 20 + }, + "id": 36, + "options": { + "reduceOptions": { + "calcs": [ + "max" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI results in resultsdb.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*complete.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) AND topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Max to resultsdb", + "type": "gauge" + }, + { + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 10 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 3, + "x": 6, + "y": 21 + }, + "id": 32, + "options": { + "reduceOptions": { + "calcs": [ + "max" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*updates-candidate.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Building the package.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Max build in minutes", + "type": "gauge" + }, + { + "datasource": null, + "description": "", + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 10 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 3, + "x": 12, + "y": 24 + }, + "id": 35, + "options": { + "reduceOptions": { + "calcs": [ + "max" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*complete.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*running.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Max testing in minutes", + "type": "gauge" + }, + { + "datasource": null, + "description": "", + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 10 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 3, + "x": 6, + "y": 25 + }, + "id": 33, + "options": { + "reduceOptions": { + "calcs": [ + "max" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "7.1.5", + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n timestamp as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*testing-.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*updates-candidate.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "timeFrom": null, + "timeShift": null, + "title": "Max signing in minutes", + "type": "gauge" + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 29 + }, + "hiddenSeries": false, + "id": 23, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select timestamp as time, CAST(array_to_string(REGEXP_MATCHES(_msg::jsonb->'output'->>-1, 'Ran for (\\d+).*'),'') as integer)/60 from messages where topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Time to complete in minutes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 37 + }, + "hiddenSeries": false, + "id": 18, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*updates-candidate.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Building the package.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Time for build in minutes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 45 + }, + "hiddenSeries": false, + "id": 19, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n timestamp as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*testing-.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*Retrieving koji tags:.*updates-candidate.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Time for signing in minutes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 53 + }, + "hiddenSeries": false, + "id": 20, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*running.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*bodhi to CI.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where $__timeFilter(\"timestamp\") and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Time in queue in minutes", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 61 + }, + "hiddenSeries": false, + "id": 21, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*complete.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*running.*DONE.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) and topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Time in testing", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": null, + "fieldConfig": { + "defaults": { + "custom": { + "align": null + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 8, + "w": 24, + "x": 0, + "y": 69 + }, + "hiddenSeries": false, + "id": 22, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select \n \"timestamp\" as time,\n EXTRACT (MINUTES FROM (TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI results in resultsdb.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME \n - \n TO_TIMESTAMP(substring(jsonb_path_query_first(_msg::jsonb,'$.output[*] ? (@ like_regex \".*CI.*complete.*D.*\")')::text,2,8), 'HH24:MI:SS')::TIME)::TIME) as interval\nfrom messages where ($__timeFilter(\"timestamp\")) AND topic like '%gating%$test%.end.%' order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Time from testing to resultsdb", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Datanommer", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 12, + "w": 24, + "x": 0, + "y": 77 + }, + "hiddenSeries": false, + "id": 15, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\ns as (select date(\"timestamp\") as time, count(*) as successful_gating_runs from messages where topic like '%gating%$test%.end%succe%' group by time)\nselect s.time as time, (s.successful_gating_runs*100)/c.finished_gating_runs as percent_succesful from c,s where c.time = s.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + }, + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with c as (select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time),\r\ns as (select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' LIKE '%CI (complete) results in datagrepper returned error%') or topic like '%gating%$test%.end%succe%' group by time)\r\nselect s.time as time, (s.ci_completed*100)/c.finished_gating_runs as percent_ci_done from c,s where c.time = s.time order by time", + "refId": "B", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Monitor Gating Success Percentage", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Datanommer", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 12, + "w": 24, + "x": 0, + "y": 89 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select date(\"timestamp\") as time, count(*) as finished_gating_runs from messages where topic like '%gating%$test%.end.%' group by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + }, + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select date(\"timestamp\") as time, count(*) as successful_gating_runs from messages where topic like '%gating%$test%.end%succe%' group by time", + "refId": "B", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + }, + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select date(\"timestamp\") as time, count(*) as ci_completed from messages where (topic like '%gating%$test%.end%fail%' and _msg::jsonb#>>'{output_text}' LIKE '%CI (complete) results in datagrepper returned error%') or topic like '%gating%$test%.end%succe%' group by time", + "refId": "C", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Monitor Gating", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + } + ], + "refresh": false, + "schemaVersion": 26, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "allValue": null, + "current": { + "selected": false, + "text": "single", + "value": "single" + }, + "hide": 0, + "includeAll": false, + "label": null, + "multi": false, + "name": "test", + "options": [ + { + "selected": true, + "text": "single", + "value": "single" + }, + { + "selected": false, + "text": "multi", + "value": "multi" + } + ], + "query": "single, multi", + "queryValue": "", + "skipUrlSync": false, + "type": "custom" + } + ] + }, + "time": { + "from": "2020-03-22T19:35:01.854Z", + "to": "2020-05-25T21:23:27.434Z" + }, + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Monitor Gating", + "uid": "6q2qpcvGz", + "version": 24 +} \ No newline at end of file diff --git a/roles/openshift-apps/monitor-dashboard/files/dashboard_package_tests.json b/roles/openshift-apps/monitor-dashboard/files/dashboard_package_tests.json new file mode 100644 index 0000000..f8b65f0 --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/dashboard_package_tests.json @@ -0,0 +1,347 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "type": "dashboard" + } + ] + }, + "editable": true, + "gnetId": null, + "graphTooltip": 0, + "id": 1, + "links": [], + "panels": [ + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Datanommer", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 11, + "w": 24, + "x": 0, + "y": 0 + }, + "hiddenSeries": false, + "id": 2, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select date(\"timestamp\") as time, count(*) as infra_fail_count from test_query_tb where topic like '%test.error' and _msg::jsonb#>>'{error,reason}' like '%Infra%' group by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + }, + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select date(\"timestamp\") as time, count(*) as execution_error_count from test_query_tb where topic like '%test.error' and _msg::jsonb#>>'{error,reason}' like '%exec%' group by time", + "refId": "B", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + }, + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "select date(\"timestamp\") as time, count(*) as faild_or_complete_total from test_query_tb where topic like '%test.error' or topic like '%test.complete' group by time", + "refId": "C", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Package tests completion and error counts", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + }, + { + "aliasColors": {}, + "bars": false, + "dashLength": 10, + "dashes": false, + "datasource": "Datanommer", + "fieldConfig": { + "defaults": { + "custom": {} + }, + "overrides": [] + }, + "fill": 1, + "fillGradient": 0, + "gridPos": { + "h": 11, + "w": 24, + "x": 0, + "y": 11 + }, + "hiddenSeries": false, + "id": 3, + "legend": { + "avg": false, + "current": false, + "max": false, + "min": false, + "show": true, + "total": false, + "values": false + }, + "lines": true, + "linewidth": 1, + "nullPointMode": "null", + "percentage": false, + "pluginVersion": "7.1.5", + "pointradius": 2, + "points": false, + "renderer": "flot", + "seriesOverrides": [], + "spaceLength": 10, + "stack": false, + "steppedLine": false, + "targets": [ + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with \n complete as (\n select date(\"timestamp\") as time, count(*) as faild_or_complete_total \n from test_query_tb where topic like '%test.error' or topic like '%test.complete' group by time),\n infra as (select date(\"timestamp\") as time, count(*) as infra_fail_count from test_query_tb where topic like '%test.error' and _msg::jsonb#>>'{error,reason}' like '%Infra%' group by time)\nselect infra.time as time, (infra.infra_fail_count*100)/complete.faild_or_complete_total as infra_failure_percent from infra, complete where infra.time = complete.time order by time", + "refId": "A", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + }, + { + "format": "time_series", + "group": [], + "metricColumn": "none", + "rawQuery": true, + "rawSql": "with \r\n complete as (\r\n select date(\"timestamp\") as time, count(*) as faild_or_complete_total \r\n from test_query_tb where topic like '%test.error' or topic like '%test.complete' group by time),\r\n infra as (select date(\"timestamp\") as time, count(*) as infra_fail_count from test_query_tb where topic like '%test.error' and _msg::jsonb#>>'{error,reason}' like '%execution%' group by time)\r\nselect infra.time as time, (infra.infra_fail_count*100)/complete.faild_or_complete_total as execution_error_percent from infra, complete where infra.time = complete.time order by time", + "refId": "B", + "select": [ + [ + { + "params": [ + "value" + ], + "type": "column" + } + ] + ], + "timeColumn": "time", + "where": [ + { + "name": "$__timeFilter", + "params": [], + "type": "macro" + } + ] + } + ], + "thresholds": [], + "timeFrom": null, + "timeRegions": [], + "timeShift": null, + "title": "Percent of failed package tests ", + "tooltip": { + "shared": true, + "sort": 0, + "value_type": "individual" + }, + "type": "graph", + "xaxis": { + "buckets": null, + "mode": "time", + "name": null, + "show": true, + "values": [] + }, + "yaxes": [ + { + "format": "short", + "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 + } + } + ], + "schemaVersion": 26, + "style": "dark", + "tags": [], + "templating": { + "list": [] + }, + "time": { + "from": "now/y", + "to": "now" + }, + "timepicker": { + "refresh_intervals": [ + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "", + "title": "Package tests completion and errors", + "uid": "PDzad5DMk", + "version": 3 + } \ No newline at end of file diff --git a/roles/openshift-apps/monitor-dashboard/files/dashboard_provision_config.yml b/roles/openshift-apps/monitor-dashboard/files/dashboard_provision_config.yml new file mode 100644 index 0000000..7eda14d --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/dashboard_provision_config.yml @@ -0,0 +1,30 @@ +apiVersion: v1 +data: + dashboards.yml: | + apiVersion: 1 + + providers: + # an unique provider name. Required + - name: 'Preset Dashboards' + # Org id. Default to 1 + orgId: 1 + # name of the dashboard folder. + folder: '' + # folder UID. will be automatically generated if not specified + folderUid: '' + # provider type. Default to 'file' + type: file + # disable dashboard deletion + disableDeletion: false + # how often Grafana will scan for changed dashboards + updateIntervalSeconds: 10 + # allow updating provisioned dashboards from the UI + allowUiUpdates: false + options: + # path to dashboard files on disk. Required when using the 'file' type + path: /var/lib/grafana/dashboards + # use folder names from filesystem to create folders in Grafana + foldersFromFilesStructure: true +kind: ConfigMap +metadata: + name: grafana-dashboards-provision \ No newline at end of file diff --git a/roles/openshift-apps/monitor-dashboard/files/dashboards.yaml b/roles/openshift-apps/monitor-dashboard/files/dashboards.yaml new file mode 100644 index 0000000..b4e9c8c --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/dashboards.yaml @@ -0,0 +1,24 @@ +apiVersion: 1 + +providers: + # an unique provider name. Required + - name: 'Preset Dashboards' + # Org id. Default to 1 + orgId: 1 + # name of the dashboard folder. + folder: '' + # folder UID. will be automatically generated if not specified + folderUid: '' + # provider type. Default to 'file' + type: file + # disable dashboard deletion + disableDeletion: false + # how often Grafana will scan for changed dashboards + updateIntervalSeconds: 10 + # allow updating provisioned dashboards from the UI + allowUiUpdates: false + options: + # path to dashboard files on disk. Required when using the 'file' type + path: /var/lib/grafana/dashboards + # use folder names from filesystem to create folders in Grafana + foldersFromFilesStructure: true diff --git a/roles/openshift-apps/monitor-dashboard/files/datasource_postgres.yaml b/roles/openshift-apps/monitor-dashboard/files/datasource_postgres.yaml new file mode 100644 index 0000000..6ad5d74 --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/datasource_postgres.yaml @@ -0,0 +1,16 @@ +apiVersion: 1 +datasources: +- name: Datanommer + type: postgres + url: postgresql:5432 + database: datanommer + user: postgres + isDefault: true + secureJsonData: + password: $DBNOMMER_PWD + jsonData: + sslmode: "disable" # disable/require/verify-ca/verify-full + maxOpenConns: 0 # Grafana v5.4+ + maxIdleConns: 2 # Grafana v5.4+ + connMaxLifetime: 14400 # Grafana v5.4+ + postgresVersion: 12000 # 903=9.3, 904=9.4, 905=9.5, 906=9.6, 1000=10 \ No newline at end of file diff --git a/roles/openshift-apps/monitor-dashboard/files/route.yml b/roles/openshift-apps/monitor-dashboard/files/route.yml new file mode 100644 index 0000000..bae3190 --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/route.yml @@ -0,0 +1,16 @@ +apiVersion: v1 +kind: Route +metadata: + name: monitor-dashboard-web + labels: + app: monitor-dashboard +spec: + #host: waiverdb.stg.fedoraproject.org + port: + targetPort: web + to: + kind: Service + name: monitor-dashboard-web + tls: + termination: edge + insecureEdgeTerminationPolicy: Redirect diff --git a/roles/openshift-apps/monitor-dashboard/files/service.yml b/roles/openshift-apps/monitor-dashboard/files/service.yml new file mode 100644 index 0000000..aa74451 --- /dev/null +++ b/roles/openshift-apps/monitor-dashboard/files/service.yml @@ -0,0 +1,14 @@ +apiVersion: v1 +kind: Service +metadata: + name: monitor-dashboard-web + labels: + app: dashboard +spec: + selector: + app: dashboard + service: web + ports: + - name: web + port: 8080 + targetPort: 3000 diff --git a/roles/openshift-apps/monitor-dashboard/templates/configmap.yml b/roles/openshift-apps/monitor-dashboard/templates/configmap.yml index 178f242..8c1a695 100644 --- a/roles/openshift-apps/monitor-dashboard/templates/configmap.yml +++ b/roles/openshift-apps/monitor-dashboard/templates/configmap.yml @@ -21,6 +21,6 @@ data: maxOpenConns: 0 # Grafana v5.4+ maxIdleConns: 2 # Grafana v5.4+ connMaxLifetime: 14400 # Grafana v5.4+ - postgresVersion: 12000 # 903=9.3, 904=9.4, 905=9.5, 906=9.6, 1000=10 + postgresVersion: 1200 # 903=9.3, 904=9.4, 905=9.5, 906=9.6, 1000=10 timescaledb: false diff --git a/roles/openshift-apps/monitor-dashboard/templates/deploymentconfig.yml b/roles/openshift-apps/monitor-dashboard/templates/deploymentconfig.yml index 74110cb..5200083 100644 --- a/roles/openshift-apps/monitor-dashboard/templates/deploymentconfig.yml +++ b/roles/openshift-apps/monitor-dashboard/templates/deploymentconfig.yml @@ -44,8 +44,18 @@ spec: - containerPort: 3000 volumeMounts: - mountPath: /etc/grafana/provisioning/datasources - name: grafana-datasources + name: grafana-datasources-provision + - mountPath: /etc/grafana/provisioning/dashboards + name: grafana-dashboards-provision + - mountPath: /var/lib/grafana/dashboards + name: grafana-dashboards volumes: - configMap: - name: grafana-datasources - name: grafana-datasources \ No newline at end of file + name: grafana-datasources-provision + name: grafana-datasources-provision + - configMap: + name: grafana-dashboards-provision + name: grafana-dashboards-provision + - configMap: + name: grafana-dashboards + name: grafana-dashboards \ No newline at end of file