Skip to content

Commit

Permalink
grafana updates (#2498) (#2505)
Browse files Browse the repository at this point in the history
  • Loading branch information
jessegoodier committed Aug 16, 2023
1 parent 9d5da84 commit 9381d5a
Show file tree
Hide file tree
Showing 5 changed files with 348 additions and 388 deletions.
2 changes: 1 addition & 1 deletion cost-analyzer/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ dependencies:
- condition: global.thanos.enabled
name: thanos
repository: file://./charts/thanos
version: "~0.29.0"
version: "~0.29.0"
1 change: 0 additions & 1 deletion cost-analyzer/charts/grafana/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ data:
prometheusVersion: 2.35.0
timeInterval: 1m
{{- end -}}
# end of if not .Values.datasources:
{{- end }}
{{- if .Values.dashboardProviders }}
{{- range $key, $value := .Values.dashboardProviders }}
Expand Down
84 changes: 43 additions & 41 deletions cost-analyzer/networkCosts-metrics.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"id": 12,
"id": 24,
"links": [],
"liveNow": false,
"panels": [
Expand Down Expand Up @@ -58,8 +58,8 @@
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"drawStyle": "bars",
"fillOpacity": 100,
"gradientMode": "none",
"hideFrom": {
"legend": false,
Expand All @@ -82,7 +82,6 @@
"mode": "off"
}
},
"decimals": 2,
"mappings": [],
"thresholds": {
"mode": "absolute",
Expand All @@ -97,7 +96,7 @@
}
]
},
"unit": "decmbytes"
"unit": "bytes"
},
"overrides": []
},
Expand Down Expand Up @@ -127,8 +126,8 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "sum by($aggregation) (increase(kubecost_pod_network_ingress_bytes_total{namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}[60m])) / 1024 / 1024",
"interval": "",
"expr": "sum(increase(kubecost_pod_network_ingress_bytes_total\n {namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]\n ))\nby($aggregation) ",
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "A"
Expand All @@ -139,8 +138,9 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "- sum by($aggregation) (increase(kubecost_pod_network_egress_bytes_total{namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}[60m])) / 1024 / 1024",
"expr": "-sum(increase(kubecost_pod_network_egress_bytes_total\n {namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]\n ))\nby($aggregation) ",
"hide": false,
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "B"
Expand All @@ -165,8 +165,8 @@
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"drawStyle": "bars",
"fillOpacity": 100,
"gradientMode": "none",
"hideFrom": {
"legend": false,
Expand Down Expand Up @@ -203,7 +203,7 @@
}
]
},
"unit": "decmbytes"
"unit": "bytes"
},
"overrides": []
},
Expand Down Expand Up @@ -233,9 +233,9 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "sum by($aggregation) (increase(kubecost_pod_network_ingress_bytes_total{internet=\"true\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}[60m])) / 1024 / 1024",
"expr": "sum(increase(kubecost_pod_network_ingress_bytes_total\n {internet=\"true\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]\n))\nby($aggregation) ",
"hide": false,
"interval": "",
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "A"
Expand All @@ -246,8 +246,9 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "- sum by($aggregation) (increase(kubecost_pod_network_egress_bytes_total{internet=\"true\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}[60m])) / 1024 / 1024",
"expr": "- sum(increase(kubecost_pod_network_egress_bytes_total\n {internet=\"true\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]))\nby($aggregation) ",
"hide": false,
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "B"
Expand All @@ -273,8 +274,8 @@
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"drawStyle": "bars",
"fillOpacity": 100,
"gradientMode": "none",
"hideFrom": {
"legend": false,
Expand Down Expand Up @@ -312,7 +313,7 @@
}
]
},
"unit": "decmbytes"
"unit": "bytes"
},
"overrides": []
},
Expand Down Expand Up @@ -342,8 +343,8 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "sum by($aggregation) (increase(kubecost_pod_network_ingress_bytes_total{internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"false\", sameZone=\"false\"}[60m])) / 1024 / 1024",
"interval": "",
"expr": "sum(increase(kubecost_pod_network_ingress_bytes_total\n {internet=\"false\",namespace=~\"$namespace\",cluster_id=~\"$cluster\",pod_name=~\"$pod\", sameRegion=\"false\",sameZone=\"false\"}\n [1h]))\nby($aggregation)",
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "A"
Expand All @@ -354,8 +355,9 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "- sum by($aggregation) (increase(kubecost_pod_network_egress_bytes_total{internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"false\", sameZone=\"false\"}[60m])) / 1024 / 1024",
"expr": "- sum(increase(kubecost_pod_network_egress_bytes_total\n {internet=\"false\", namespace=~\"$namespace\",cluster_id=~\"$cluster\",pod_name=~\"$pod\",sameRegion=\"false\", sameZone=\"false\"}\n [1h]))\nby($aggregation) ",
"hide": false,
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "B"
Expand All @@ -381,8 +383,8 @@
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 0,
"drawStyle": "bars",
"fillOpacity": 100,
"gradientMode": "none",
"hideFrom": {
"legend": false,
Expand Down Expand Up @@ -420,7 +422,7 @@
}
]
},
"unit": "decmbytes"
"unit": "bytes"
},
"overrides": []
},
Expand Down Expand Up @@ -450,8 +452,8 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "sum by($aggregation) (increase(kubecost_pod_network_ingress_bytes_total{internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"true\", sameZone=\"false\"}[60m])) / 1024 / 1024",
"interval": "",
"expr": "sum(increase(kubecost_pod_network_ingress_bytes_total\n {internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"true\", sameZone=\"false\"}\n [1h]))\nby($aggregation)",
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "A"
Expand All @@ -462,8 +464,9 @@
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "- sum by($aggregation) (increase(kubecost_pod_network_egress_bytes_total{internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"true\", sameZone=\"false\"}[60m])) / 1024 / 1024",
"expr": "- sum(increase(kubecost_pod_network_egress_bytes_total\n {internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"true\", sameZone=\"false\"}\n [1h]))\nby($aggregation)",
"hide": false,
"interval": "1h",
"legendFormat": "__auto",
"range": true,
"refId": "B"
Expand All @@ -473,19 +476,18 @@
"type": "timeseries"
}
],
"refresh": false,
"schemaVersion": 37,
"refresh": "",
"revision": 1,
"schemaVersion": 38,
"style": "dark",
"tags": [
"utilization",
"metrics",
"kubecost"
],
"templating": {
"list": [
{
"current": {
"selected": false,
"selected": true,
"text": "Prometheus",
"value": "Prometheus"
},
Expand All @@ -504,8 +506,8 @@
{
"current": {
"selected": true,
"text": "namespace",
"value": "namespace"
"text": "pod",
"value": "pod"
},
"hide": 0,
"includeAll": false,
Expand All @@ -518,17 +520,17 @@
"value": "cluster_id"
},
{
"selected": true,
"selected": false,
"text": "namespace",
"value": "namespace"
},
{
"selected": false,
"text": "pod_name",
"value": "pod_name"
"selected": true,
"text": "pod",
"value": "pod"
}
],
"query": "cluster_id, namespace, pod_name",
"query": "cluster_id, namespace, pod",
"queryValue": "",
"skipUrlSync": false,
"type": "custom"
Expand Down Expand Up @@ -562,8 +564,8 @@
{
"current": {
"selected": false,
"text": "All",
"value": "$__all"
"text": "kubecost",
"value": "kubecost"
},
"datasource": {
"type": "prometheus",
Expand Down Expand Up @@ -632,6 +634,6 @@
"timezone": "",
"title": "Kubecost networkCosts Metrics",
"uid": "kubecost-networkCosts-metrics",
"version": 7,
"version": 8,
"weekStart": ""
}
Loading

0 comments on commit 9381d5a

Please sign in to comment.