diff --git a/dashboards/platform/s3.json b/dashboards/platform/s3.json index 9babeef..eda450a 100644 --- a/dashboards/platform/s3.json +++ b/dashboards/platform/s3.json @@ -26,218 +26,6 @@ "description": "", "fieldConfig": { "defaults": { - "mappings": [ - { - "options": { - "1": { - "text": "HEALTHY" - } - }, - "type": "value" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "#d44a3a" - }, - { - "color": "rgba(237, 129, 40, 0.89)", - "value": 0 - }, - { - "color": "#299c46", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 0, - "y": 0 - }, - "id": 2, - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "percentChangeColorMode": "standard", - "reduceOptions": { - "calcs": ["lastNotNull"], - "fields": "", - "values": false - }, - "showPercentChange": false, - "textMode": "auto", - "wideLayout": true - }, - "pluginVersion": "12.0.0", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${DS_PROMETHEUS}" - }, - "expr": "s3_endpoint_up{s3name=\"$s3name\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "title": "Status", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${DS_PROMETHEUS}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisBorderShow": false, - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "barWidthFactor": 0.6, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 11, - "w": 10, - "x": 4, - "y": 0 - }, - "id": 10, - "options": { - "legend": { - "calcs": ["lastNotNull"], - "displayMode": "list", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "hideZeros": false, - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "12.0.0", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${DS_PROMETHEUS}" - }, - "expr": "s3_bucket_size{s3name=\"$s3name\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{ bucketname }}", - "refId": "A" - } - ], - "title": "Storage Usage ", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${DS_PROMETHEUS}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisBorderShow": false, - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "barWidthFactor": 0.6, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, "mappings": [], "thresholds": { "mode": "absolute", @@ -256,24 +44,27 @@ "overrides": [] }, "gridPos": { - "h": 11, - "w": 10, - "x": 14, + "h": 2, + "w": 24, + "x": 0, "y": 0 }, - "id": 11, + "id": 2, + "maxDataPoints": 100, "options": { - "legend": { + "colorMode": "background", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "auto", + "percentChangeColorMode": "standard", + "reduceOptions": { "calcs": ["lastNotNull"], - "displayMode": "list", - "placement": "bottom", - "showLegend": true + "fields": "", + "values": false }, - "tooltip": { - "hideZeros": false, - "mode": "multi", - "sort": "none" - } + "showPercentChange": false, + "textMode": "none", + "wideLayout": true }, "pluginVersion": "12.0.0", "targets": [ @@ -282,16 +73,31 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS}" }, - "expr": "s3_bucket_object_number{s3name=\"$s3name\"}", + "editorMode": "code", + "expr": "s3_endpoint_up{s3name=\"$s3name\"}", "format": "time_series", "interval": "", "intervalFactor": 1, - "legendFormat": "{{ bucketname }}", + "legendFormat": "", + "range": true, "refId": "A" } ], - "title": "Object Count", - "type": "timeseries" + "title": "Endpoint Status", + "type": "stat" + }, + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 2 + }, + "id": 14, + "panels": [], + "title": "Bucket", + "type": "row" }, { "datasource": { @@ -300,6 +106,11 @@ }, "fieldConfig": { "defaults": { + "color": { + "fixedColor": "text", + "mode": "fixed" + }, + "decimals": 1, "mappings": [], "thresholds": { "mode": "absolute", @@ -322,7 +133,7 @@ "overrides": [] }, "gridPos": { - "h": 4, + "h": 5, "w": 4, "x": 0, "y": 3 @@ -351,10 +162,12 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS}" }, - "expr": "s3_total_size{s3name=\"$s3name\"}", + "editorMode": "code", + "expr": "avg(s3_bucket_size{s3name=\"$s3name\", bucketname=\"$bucketname\"})", "format": "time_series", "intervalFactor": 1, "legendFormat": "", + "range": true, "refId": "A" } ], @@ -368,6 +181,214 @@ }, "fieldConfig": { "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "opacity", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "smooth", + "lineWidth": 2, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": true, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "decimals": 0, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + } + ] + }, + "unit": "decbytes" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 10, + "x": 4, + "y": 3 + }, + "id": 10, + "options": { + "legend": { + "calcs": ["lastNotNull"], + "displayMode": "list", + "placement": "bottom", + "showLegend": false + }, + "tooltip": { + "hideZeros": true, + "mode": "multi", + "sort": "none" + } + }, + "pluginVersion": "12.0.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "disableTextWrap": false, + "editorMode": "code", + "expr": "avg(s3_bucket_size{s3name=\"$s3name\", bucketname=\"$bucketname\"})", + "format": "time_series", + "fullMetaSearch": false, + "includeNullMetadata": true, + "interval": "", + "intervalFactor": 1, + "legendFormat": "{{ bucketname }}", + "range": true, + "refId": "A", + "useBackend": false + } + ], + "title": "Storage Usage ", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisBorderShow": false, + "axisCenteredZero": false, + "axisColorMode": "text", + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "barWidthFactor": 0.6, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "opacity", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "insertNulls": false, + "lineInterpolation": "smooth", + "lineWidth": 2, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": true, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "min": 0, + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + } + ] + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 10, + "x": 14, + "y": 3 + }, + "id": 11, + "options": { + "legend": { + "calcs": ["lastNotNull"], + "displayMode": "list", + "placement": "bottom", + "showLegend": false + }, + "tooltip": { + "hideZeros": false, + "mode": "multi", + "sort": "none" + } + }, + "pluginVersion": "12.0.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "disableTextWrap": false, + "editorMode": "code", + "expr": "avg(s3_bucket_object_number{s3name=\"$s3name\", bucketname=\"$bucketname\"})", + "format": "time_series", + "fullMetaSearch": false, + "includeNullMetadata": true, + "interval": "", + "intervalFactor": 1, + "legendFormat": "{{ bucketname }}", + "range": true, + "refId": "A", + "useBackend": false + } + ], + "title": "Object Count", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "fieldConfig": { + "defaults": { + "color": { + "fixedColor": "text", + "mode": "fixed" + }, + "decimals": 0, "mappings": [ { "options": { @@ -400,10 +421,10 @@ "overrides": [] }, "gridPos": { - "h": 4, + "h": 5, "w": 4, "x": 0, - "y": 7 + "y": 8 }, "id": 13, "maxDataPoints": 100, @@ -429,11 +450,13 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS}" }, - "expr": "s3_total_object_number{s3name=\"$s3name\"}", + "editorMode": "code", + "expr": "avg(s3_bucket_object_number{s3name=\"$s3name\", bucketname=\"$bucketname\"})", "format": "time_series", "interval": "", "intervalFactor": 1, "legendFormat": "", + "range": true, "refId": "A" } ], @@ -446,11 +469,11 @@ "h": 1, "w": 24, "x": 0, - "y": 11 + "y": 13 }, "id": 9, "panels": [], - "title": "Total", + "title": "Endpoint Total", "type": "row" }, { @@ -460,20 +483,17 @@ }, "fieldConfig": { "defaults": { + "color": { + "fixedColor": "blue", + "mode": "fixed" + }, + "decimals": 1, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "#3274D9" - }, - { - "color": "#3274D9", - "value": 0 - }, - { - "color": "#3274D9", - "value": 1 } ] }, @@ -485,7 +505,7 @@ "h": 6, "w": 4, "x": 0, - "y": 12 + "y": 14 }, "id": 5, "maxDataPoints": 100, @@ -511,10 +531,12 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS}" }, + "editorMode": "code", "expr": "s3_total_size{s3name=\"$s3name\"}", "format": "time_series", "intervalFactor": 1, "legendFormat": "", + "range": true, "refId": "A" } ], @@ -541,21 +563,21 @@ "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, - "gradientMode": "none", + "gradientMode": "opacity", "hideFrom": { "legend": false, "tooltip": false, "viz": false }, "insertNulls": false, - "lineInterpolation": "linear", - "lineWidth": 1, + "lineInterpolation": "smooth", + "lineWidth": 2, "pointSize": 5, "scaleDistribution": { "type": "linear" }, "showPoints": "never", - "spanNulls": false, + "spanNulls": true, "stacking": { "group": "A", "mode": "none" @@ -564,7 +586,9 @@ "mode": "off" } }, + "decimals": 1, "mappings": [], + "min": 0, "thresholds": { "mode": "absolute", "steps": [ @@ -585,14 +609,14 @@ "h": 6, "w": 20, "x": 4, - "y": 12 + "y": 14 }, "id": 4, "options": { "legend": { "calcs": ["lastNotNull"], - "displayMode": "list", - "placement": "bottom", + "displayMode": "table", + "placement": "right", "showLegend": true }, "tooltip": { @@ -608,12 +632,18 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS}" }, - "expr": "s3_bucket_size{s3name=\"$s3name\"}", + "disableTextWrap": false, + "editorMode": "code", + "expr": "avg by(bucketname) (s3_bucket_size{s3name=\"$s3name\"})", "format": "time_series", + "fullMetaSearch": false, + "includeNullMetadata": true, "interval": "", "intervalFactor": 1, "legendFormat": "{{ bucketname }}", - "refId": "A" + "range": true, + "refId": "A", + "useBackend": false } ], "title": "Storage Usage ", @@ -626,6 +656,10 @@ }, "fieldConfig": { "defaults": { + "color": { + "fixedColor": "blue", + "mode": "fixed" + }, "mappings": [ { "options": { @@ -642,14 +676,6 @@ "steps": [ { "color": "#3274D9" - }, - { - "color": "#3274D9", - "value": 0 - }, - { - "color": "#3274D9", - "value": 1 } ] }, @@ -661,7 +687,7 @@ "h": 6, "w": 4, "x": 0, - "y": 18 + "y": 20 }, "id": 6, "maxDataPoints": 100, @@ -687,11 +713,13 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS}" }, + "editorMode": "code", "expr": "s3_total_object_number{s3name=\"$s3name\"}", "format": "time_series", "interval": "", "intervalFactor": 1, "legendFormat": "", + "range": true, "refId": "A" } ], @@ -718,21 +746,21 @@ "barWidthFactor": 0.6, "drawStyle": "line", "fillOpacity": 10, - "gradientMode": "none", + "gradientMode": "opacity", "hideFrom": { "legend": false, "tooltip": false, "viz": false }, "insertNulls": false, - "lineInterpolation": "linear", - "lineWidth": 1, + "lineInterpolation": "smooth", + "lineWidth": 2, "pointSize": 5, "scaleDistribution": { "type": "linear" }, "showPoints": "never", - "spanNulls": false, + "spanNulls": true, "stacking": { "group": "A", "mode": "none" @@ -741,7 +769,9 @@ "mode": "off" } }, + "decimals": 0, "mappings": [], + "min": 0, "thresholds": { "mode": "absolute", "steps": [ @@ -762,14 +792,14 @@ "h": 6, "w": 20, "x": 4, - "y": 18 + "y": 20 }, "id": 8, "options": { "legend": { "calcs": ["lastNotNull"], - "displayMode": "list", - "placement": "bottom", + "displayMode": "table", + "placement": "right", "showLegend": true }, "tooltip": { @@ -785,12 +815,18 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS}" }, - "expr": "s3_bucket_object_number{s3name=\"$s3name\"}", + "disableTextWrap": false, + "editorMode": "code", + "expr": "avg by(bucketname) (s3_bucket_object_number{s3name=\"$s3name\"})", "format": "time_series", + "fullMetaSearch": false, + "includeNullMetadata": true, "interval": "", "intervalFactor": 1, "legendFormat": "{{ bucketname }}", - "refId": "A" + "range": true, + "refId": "A", + "useBackend": false } ], "title": "Object Count", @@ -801,41 +837,6 @@ "tags": ["platform", "storage", "external"], "templating": { "list": [ - { - "current": { - "text": "", - "value": "" - }, - "definition": "label_values()", - "label": "S3 Name", - "name": "s3name", - "options": [], - "query": { - "qryType": 1, - "query": "label_values()", - "refId": "PrometheusVariableQueryEditor-VariableQuery" - }, - "refresh": 1, - "regex": "", - "type": "query" - }, - { - "current": { - "text": "", - "value": "" - }, - "datasource": "kube-prometheus-stack", - "definition": "label_values(s3name)", - "includeAll": false, - "label": "Bucket", - "name": "bucket", - "options": [], - "query": "label_values(s3name)", - "refresh": 1, - "regex": "", - "sort": 1, - "type": "query" - }, { "current": { "text": "Prometheus", @@ -848,6 +849,43 @@ "refresh": 1, "regex": "", "type": "datasource" + }, + { + "current": { + "text": "digital-ocean", + "value": "digital-ocean" + }, + "datasource": "kube-prometheus-stack", + "definition": "label_values(s3name)", + "includeAll": false, + "label": "Endpoint", + "name": "s3name", + "options": [], + "query": "label_values(s3name)", + "refresh": 1, + "regex": "", + "sort": 1, + "type": "query" + }, + { + "allowCustomValue": true, + "current": { + "text": "gitea-backups-8ba8dae3674a2f53354c600e", + "value": "gitea-backups-8ba8dae3674a2f53354c600e" + }, + "definition": "label_values({s3name=\"$s3name\"},bucketname)", + "includeAll": false, + "label": "Bucket", + "name": "bucketname", + "options": [], + "query": { + "qryType": 1, + "query": "label_values({s3name=\"$s3name\"},bucketname)", + "refId": "PrometheusVariableQueryEditor-VariableQuery" + }, + "refresh": 1, + "regex": "", + "type": "query" } ] },