Skip to content

Commit

Permalink
fix(monitoring): Filter out negative values
Browse files Browse the repository at this point in the history
Negative values indicate failured in the metrics collection.
They produce unclear jumps in the time series and influence the
min and mean values.

In addition, the color of the mean value was wrong. This is fixed.
  • Loading branch information
MoritzWeber0 committed Jun 6, 2024
1 parent e1d730c commit ca57f61
Showing 1 changed file with 101 additions and 2 deletions.
103 changes: 101 additions & 2 deletions helm/config/grafana/team4capella.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,24 @@
}
]
}
},
{
"id": "filterByValue",
"options": {
"filters": [
{
"config": {
"id": "greaterOrEqual",
"options": {
"value": 0
}
},
"fieldName": "max(used_t4c_licenses)"
}
],
"match": "any",
"type": "include"
}
}
],
"type": "stat"
Expand All @@ -121,7 +139,7 @@
"fieldConfig": {
"defaults": {
"color": {
"mode": "continuous-RdYlGr"
"mode": "continuous-GrYlRd"
},
"mappings": [],
"min": 0,
Expand Down Expand Up @@ -178,7 +196,7 @@
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
},
"editorMode": "builder",
"editorMode": "code",
"expr": "max(total_t4c_licenses)",
"hide": false,
"instant": false,
Expand All @@ -199,6 +217,24 @@
}
]
}
},
{
"id": "filterByValue",
"options": {
"filters": [
{
"config": {
"id": "greaterOrEqual",
"options": {
"value": 0
}
},
"fieldName": "max(used_t4c_licenses)"
}
],
"match": "any",
"type": "include"
}
}
],
"type": "stat"
Expand Down Expand Up @@ -289,6 +325,24 @@
}
]
}
},
{
"id": "filterByValue",
"options": {
"filters": [
{
"config": {
"id": "greaterOrEqual",
"options": {
"value": 0
}
},
"fieldName": "max(used_t4c_licenses)"
}
],
"match": "any",
"type": "include"
}
}
],
"type": "stat"
Expand Down Expand Up @@ -378,6 +432,24 @@
}
]
}
},
{
"id": "filterByValue",
"options": {
"filters": [
{
"config": {
"id": "greaterOrEqual",
"options": {
"value": 0
}
},
"fieldName": "max(total_t4c_licenses)"
}
],
"match": "any",
"type": "include"
}
}
],
"type": "stat"
Expand Down Expand Up @@ -518,6 +590,33 @@
}
]
}
},
{
"id": "filterByValue",
"options": {
"filters": [
{
"config": {
"id": "greaterOrEqual",
"options": {
"value": 0
}
},
"fieldName": "Total licenses"
},
{
"config": {
"id": "greaterOrEqual",
"options": {
"value": 0
}
},
"fieldName": "Used licenses"
}
],
"match": "any",
"type": "include"
}
}
],
"type": "timeseries"
Expand Down

0 comments on commit ca57f61

Please sign in to comment.