Update minitor dashboard

This commit is contained in:
IamTheFij 2022-11-16 08:35:01 -08:00
parent 12b91e9566
commit 416676c9f9

View File

@ -3,36 +3,72 @@
"list": [ "list": [
{ {
"builtIn": 1, "builtIn": 1,
"datasource": "-- Grafana --", "datasource": {
"type": "datasource",
"uid": "grafana"
},
"enable": true, "enable": true,
"hide": true, "hide": true,
"iconColor": "rgba(0, 211, 255, 1)", "iconColor": "rgba(0, 211, 255, 1)",
"name": "Annotations & Alerts", "name": "Annotations & Alerts",
"target": {
"limit": 100,
"matchAny": false,
"tags": [],
"type": "dashboard"
},
"type": "dashboard" "type": "dashboard"
} }
] ]
}, },
"editable": true, "editable": true,
"gnetId": null, "fiscalYearStartMonth": 0,
"graphTooltip": 0, "graphTooltip": 0,
"links": [], "links": [],
"liveNow": false,
"panels": [ "panels": [
{ {
"cacheTimeout": null, "datasource": {
"colorBackground": false, "type": "prometheus",
"colorValue": false, "uid": "rS2OIfv4z"
"colors": [ },
"#d44a3a", "fieldConfig": {
"rgba(237, 129, 40, 0.89)", "defaults": {
"#299c46" "color": {
"fixedColor": "rgb(31, 120, 193)",
"mode": "fixed"
},
"mappings": [
{
"options": {
"match": "null",
"result": {
"text": "N/A"
}
},
"type": "special"
}
], ],
"format": "none", "thresholds": {
"gauge": { "mode": "absolute",
"maxValue": 100, "steps": [
"minValue": 0, {
"show": false, "color": "#d44a3a",
"thresholdLabels": false, "value": null
"thresholdMarkers": true },
{
"color": "rgba(237, 129, 40, 0.89)",
"value": 0
},
{
"color": "#299c46",
"value": 1
}
]
},
"unit": "none"
},
"overrides": []
}, },
"gridPos": { "gridPos": {
"h": 7, "h": 7,
@ -41,43 +77,29 @@
"y": 0 "y": 0
}, },
"id": 2, "id": 2,
"interval": null,
"links": [], "links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100, "maxDataPoints": 100,
"nullPointMode": "connected", "options": {
"nullText": null, "colorMode": "none",
"options": {}, "graphMode": "area",
"postfix": "", "justifyMode": "auto",
"postfixFontSize": "50%", "orientation": "horizontal",
"prefix": "", "reduceOptions": {
"prefixFontSize": "50%", "calcs": [
"rangeMaps": [ "lastNotNull"
{
"from": "null",
"text": "N/A",
"to": "null"
}
], ],
"sparkline": { "fields": "",
"fillColor": "rgba(31, 118, 189, 0.18)", "values": false
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": true
}, },
"tableColumn": "", "textMode": "auto"
},
"pluginVersion": "9.2.4",
"targets": [ "targets": [
{ {
"datasource": {
"type": "prometheus",
"uid": "rS2OIfv4z"
},
"expr": "count(minitor_monitor_up_count)", "expr": "count(minitor_monitor_up_count)",
"format": "time_series", "format": "time_series",
"instant": true, "instant": true,
@ -85,37 +107,51 @@
"refId": "A" "refId": "A"
} }
], ],
"thresholds": "0,1",
"title": "Total Monitors", "title": "Total Monitors",
"type": "singlestat", "type": "stat"
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "current"
}, },
{ {
"cacheTimeout": null, "datasource": {
"colorBackground": true, "type": "prometheus",
"colorPrefix": false, "uid": "rS2OIfv4z"
"colorValue": false, },
"colors": [ "fieldConfig": {
"#299c46", "defaults": {
"rgba(237, 129, 40, 0.89)", "color": {
"#d44a3a" "mode": "thresholds"
], },
"decimals": 0, "decimals": 0,
"format": "none", "mappings": [
"gauge": { {
"maxValue": 100, "options": {
"minValue": 0, "match": "null",
"show": false, "result": {
"thresholdLabels": false, "text": "N/A"
"thresholdMarkers": true }
},
"type": "special"
}
],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "#299c46",
"value": null
},
{
"color": "rgba(237, 129, 40, 0.89)",
"value": 1
},
{
"color": "#d44a3a",
"value": 2
}
]
},
"unit": "none"
},
"overrides": []
}, },
"gridPos": { "gridPos": {
"h": 7, "h": 7,
@ -124,43 +160,29 @@
"y": 0 "y": 0
}, },
"id": 6, "id": 6,
"interval": null,
"links": [], "links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100, "maxDataPoints": 100,
"nullPointMode": "connected", "options": {
"nullText": null, "colorMode": "background",
"options": {}, "graphMode": "area",
"postfix": "", "justifyMode": "auto",
"postfixFontSize": "50%", "orientation": "horizontal",
"prefix": "", "reduceOptions": {
"prefixFontSize": "50%", "calcs": [
"rangeMaps": [ "lastNotNull"
{
"from": "null",
"text": "N/A",
"to": "null"
}
], ],
"sparkline": { "fields": "",
"fillColor": "rgba(31, 118, 189, 0.18)", "values": false
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": true
}, },
"tableColumn": "", "textMode": "auto"
},
"pluginVersion": "9.2.4",
"targets": [ "targets": [
{ {
"datasource": {
"type": "prometheus",
"uid": "rS2OIfv4z"
},
"expr": "count(minitor_monitor_up_count)-count(minitor_monitor_up_count>=1)", "expr": "count(minitor_monitor_up_count)-count(minitor_monitor_up_count>=1)",
"format": "time_series", "format": "time_series",
"instant": false, "instant": false,
@ -168,61 +190,60 @@
"refId": "A" "refId": "A"
} }
], ],
"thresholds": "1,2,3",
"timeFrom": null,
"title": "Total Down Services", "title": "Total Down Services",
"type": "singlestat", "type": "stat"
"valueFontSize": "80%", },
"valueMaps": [
{ {
"op": "=", "datasource": {
"text": "N/A", "type": "prometheus",
"value": "null" "uid": "rS2OIfv4z"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"custom": {
"fillOpacity": 70,
"lineWidth": 0,
"spanNulls": 900000
},
"mappings": [
{
"options": {
"0": {
"index": 1,
"text": "Down"
},
"1": {
"index": 0,
"text": "Up"
}
},
"type": "value"
} }
], ],
"valueName": "current" "thresholds": {
"mode": "absolute",
"steps": [
{
"color": "red",
"value": null
}, },
{ {
"alert": { "color": "red",
"conditions": [ "value": 0
},
{ {
"evaluator": { "color": "green",
"params": [ "value": 1
1 }
],
"type": "lt"
},
"operator": {
"type": "and"
},
"query": {
"params": [
"A",
"5m",
"now"
] ]
}, },
"reducer": { "unit": "bool_on_off"
"params": [],
"type": "last"
}, },
"type": "query" "overrides": []
}
],
"executionErrorState": "alerting",
"for": "0m",
"frequency": "60s",
"handler": 1,
"name": "Service Status alert",
"noDataState": "no_data",
"notifications": []
}, },
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"decimals": 0,
"fill": 1,
"gridPos": { "gridPos": {
"h": 7, "h": 7,
"w": 14, "w": 14,
@ -230,90 +251,49 @@
"y": 0 "y": 0
}, },
"id": 4, "id": 4,
"legend": {
"alignAsTable": false,
"avg": false,
"current": true,
"max": false,
"min": false,
"rightSide": false,
"show": true,
"total": false,
"values": true
},
"lines": true,
"linewidth": 1,
"links": [], "links": [],
"nullPointMode": "null", "options": {
"options": {}, "alignValue": "left",
"percentage": false, "legend": {
"pointradius": 5, "displayMode": "list",
"points": false, "placement": "bottom",
"renderer": "flot", "showLegend": false
"seriesOverrides": [], },
"spaceLength": 10, "mergeValues": true,
"stack": false, "rowHeight": 0.9,
"steppedLine": false, "showValue": "never",
"tooltip": {
"mode": "single",
"sort": "none"
}
},
"pluginVersion": "9.2.4",
"targets": [ "targets": [
{ {
"datasource": {
"type": "prometheus",
"uid": "rS2OIfv4z"
},
"editorMode": "code",
"exemplar": false,
"expr": "sum(minitor_monitor_up_count) by (monitor)", "expr": "sum(minitor_monitor_up_count) by (monitor)",
"format": "time_series", "format": "time_series",
"instant": false,
"intervalFactor": 1, "intervalFactor": 1,
"legendFormat": "{{monitor}}", "legendFormat": "{{monitor}}",
"range": true,
"refId": "A" "refId": "A"
} }
], ],
"thresholds": [
{
"colorMode": "critical",
"fill": true,
"line": true,
"op": "lt",
"value": 1
}
],
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "Service Status", "title": "Service Status",
"tooltip": { "type": "state-timeline"
"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
}
}, },
{ {
"columns": [], "columns": [],
"datasource": {
"type": "prometheus",
"uid": "rS2OIfv4z"
},
"fontSize": "100%", "fontSize": "100%",
"gridPos": { "gridPos": {
"h": 11, "h": 11,
@ -323,8 +303,6 @@
}, },
"id": 8, "id": 8,
"links": [], "links": [],
"options": {},
"pageSize": null,
"scroll": true, "scroll": true,
"showHeader": true, "showHeader": true,
"sort": { "sort": {
@ -334,12 +312,14 @@
"styles": [ "styles": [
{ {
"alias": "Time", "alias": "Time",
"align": "auto",
"dateFormat": "YYYY-MM-DD HH:mm:ss", "dateFormat": "YYYY-MM-DD HH:mm:ss",
"pattern": "Time", "pattern": "Time",
"type": "date" "type": "date"
}, },
{ {
"alias": "Status", "alias": "Status",
"align": "auto",
"colorMode": "cell", "colorMode": "cell",
"colors": [ "colors": [
"#F2495C", "#F2495C",
@ -370,6 +350,10 @@
], ],
"targets": [ "targets": [
{ {
"datasource": {
"type": "prometheus",
"uid": "rS2OIfv4z"
},
"expr": "minitor_monitor_up_count", "expr": "minitor_monitor_up_count",
"format": "time_series", "format": "time_series",
"instant": true, "instant": true,
@ -378,15 +362,13 @@
"refId": "A" "refId": "A"
} }
], ],
"timeFrom": null,
"timeShift": null,
"title": "Monitor status", "title": "Monitor status",
"transform": "timeseries_to_rows", "transform": "timeseries_to_rows",
"type": "table" "type": "table-old"
} }
], ],
"refresh": "30s", "refresh": "30s",
"schemaVersion": 18, "schemaVersion": 37,
"style": "dark", "style": "dark",
"tags": [], "tags": [],
"templating": { "templating": {
@ -424,5 +406,6 @@
"timezone": "", "timezone": "",
"title": "Minitor Monitor", "title": "Minitor Monitor",
"uid": "qoE5Hrxiz", "uid": "qoE5Hrxiz",
"version": 3 "version": 1,
"weekStart": ""
} }