Compare commits

...

1 Commits

Author SHA1 Message Date
Haley Wang
1cc1d45503 vmalert-dashboard: fix stats panels visualization 2025-01-08 22:24:20 +08:00
4 changed files with 64 additions and 20 deletions

View File

@@ -143,7 +143,7 @@
"type": "victoriametrics-datasource",
"uid": "$ds"
},
"description": "Shows if the last configuration update was successful. \"Not Ok\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"description": "Shows if the last configuration update was successful. \"Not OK\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"fieldConfig": {
"defaults": {
"mappings": [
@@ -152,7 +152,7 @@
"0": {
"color": "green",
"index": 0,
"text": "Ok"
"text": "OK"
}
},
"type": "value"
@@ -163,11 +163,21 @@
"result": {
"color": "red",
"index": 1,
"text": "Not Ok"
"text": "Not OK"
},
"to": 999999
},
"type": "range"
},
{
"options": {
"match": "null",
"result": {
"index": 2,
"text": "OK"
}
},
"type": "special"
}
],
"thresholds": {
@@ -214,7 +224,7 @@
"uid": "$ds"
},
"exemplar": false,
"expr": "count(vmalert_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 ) or 0",
"expr": "count(vmalert_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 )",
"interval": "",
"legendFormat": "",
"refId": "A"
@@ -359,6 +369,7 @@
"defaults": {
"mappings": [],
"min": 0,
"noValue": "0",
"thresholds": {
"mode": "absolute",
"steps": [
@@ -407,7 +418,7 @@
"uid": "$ds"
},
"exemplar": false,
"expr": "(sum(increase(vmalert_alerting_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval])) or vector(0)) + \n(sum(increase(vmalert_recording_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval])) or vector(0))",
"expr": "sum(increase(vmalert_alerting_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval])) + \nsum(increase(vmalert_recording_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval]))",
"interval": "",
"legendFormat": "",
"refId": "A"
@@ -426,6 +437,7 @@
"defaults": {
"mappings": [],
"min": 0,
"noValue": "0",
"thresholds": {
"mode": "absolute",
"steps": [
@@ -475,7 +487,7 @@
},
"editorMode": "code",
"exemplar": false,
"expr": "count(vmalert_recording_rules_last_evaluation_samples{job=~\"$job\", instance=~\"$instance\"} < 1) or 0",
"expr": "count(vmalert_recording_rules_last_evaluation_samples{job=~\"$job\", instance=~\"$instance\"} < 1)",
"interval": "",
"legendFormat": "",
"range": true,

View File

@@ -225,7 +225,7 @@
"type": "victoriametrics-datasource",
"uid": "$ds"
},
"description": "Shows if the last configuration update was successful. \"Not Ok\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"description": "Shows if the last configuration update was successful. \"Not OK\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"fieldConfig": {
"defaults": {
"mappings": [
@@ -234,7 +234,7 @@
"0": {
"color": "green",
"index": 0,
"text": "Ok"
"text": "OK"
}
},
"type": "value"
@@ -245,11 +245,21 @@
"result": {
"color": "red",
"index": 1,
"text": "Not Ok"
"text": "Not OK"
},
"to": 999999
},
"type": "range"
},
{
"options": {
"match": "null",
"result": {
"index": 2,
"text": "OK"
}
},
"type": "special"
}
],
"thresholds": {
@@ -296,7 +306,7 @@
"uid": "$ds"
},
"exemplar": false,
"expr": "count(vmauth_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 ) or 0",
"expr": "count(vmauth_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 )",
"interval": "",
"legendFormat": "",
"refId": "A"

View File

@@ -142,7 +142,7 @@
"type": "prometheus",
"uid": "$ds"
},
"description": "Shows if the last configuration update was successful. \"Not Ok\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"description": "Shows if the last configuration update was successful. \"Not OK\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"fieldConfig": {
"defaults": {
"mappings": [
@@ -151,7 +151,7 @@
"0": {
"color": "green",
"index": 0,
"text": "Ok"
"text": "OK"
}
},
"type": "value"
@@ -162,11 +162,21 @@
"result": {
"color": "red",
"index": 1,
"text": "Not Ok"
"text": "Not OK"
},
"to": 999999
},
"type": "range"
},
{
"options": {
"match": "null",
"result": {
"index": 2,
"text": "OK"
}
},
"type": "special"
}
],
"thresholds": {
@@ -213,7 +223,7 @@
"uid": "$ds"
},
"exemplar": false,
"expr": "count(vmalert_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 ) or 0",
"expr": "count(vmalert_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 )",
"interval": "",
"legendFormat": "",
"refId": "A"
@@ -358,6 +368,7 @@
"defaults": {
"mappings": [],
"min": 0,
"noValue": "0",
"thresholds": {
"mode": "absolute",
"steps": [
@@ -406,7 +417,7 @@
"uid": "$ds"
},
"exemplar": false,
"expr": "(sum(increase(vmalert_alerting_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval])) or vector(0)) + \n(sum(increase(vmalert_recording_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval])) or vector(0))",
"expr": "sum(increase(vmalert_alerting_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval])) + \nsum(increase(vmalert_recording_rules_errors_total{job=~\"$job\", instance=~\"$instance\", group=~\"$group\", file=~\"$file\"}[$__rate_interval]))",
"interval": "",
"legendFormat": "",
"refId": "A"
@@ -425,6 +436,7 @@
"defaults": {
"mappings": [],
"min": 0,
"noValue": "0",
"thresholds": {
"mode": "absolute",
"steps": [
@@ -474,7 +486,7 @@
},
"editorMode": "code",
"exemplar": false,
"expr": "count(vmalert_recording_rules_last_evaluation_samples{job=~\"$job\", instance=~\"$instance\"} < 1) or 0",
"expr": "count(vmalert_recording_rules_last_evaluation_samples{job=~\"$job\", instance=~\"$instance\"} < 1)",
"interval": "",
"legendFormat": "",
"range": true,

View File

@@ -224,7 +224,7 @@
"type": "prometheus",
"uid": "$ds"
},
"description": "Shows if the last configuration update was successful. \"Not Ok\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"description": "Shows if the last configuration update was successful. \"Not OK\" means there was an unsuccessful attempt to update the configuration due to some error. Check the log for details.",
"fieldConfig": {
"defaults": {
"mappings": [
@@ -233,7 +233,7 @@
"0": {
"color": "green",
"index": 0,
"text": "Ok"
"text": "OK"
}
},
"type": "value"
@@ -244,11 +244,21 @@
"result": {
"color": "red",
"index": 1,
"text": "Not Ok"
"text": "Not OK"
},
"to": 999999
},
"type": "range"
},
{
"options": {
"match": "null",
"result": {
"index": 2,
"text": "OK"
}
},
"type": "special"
}
],
"thresholds": {
@@ -295,7 +305,7 @@
"uid": "$ds"
},
"exemplar": false,
"expr": "count(vmauth_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 ) or 0",
"expr": "count(vmauth_config_last_reload_successful{job=~\"$job\", instance=~\"$instance\"} < 1 )",
"interval": "",
"legendFormat": "",
"refId": "A"