From 66a7332be15c661596aac8ff69a1b8f05655d199 Mon Sep 17 00:00:00 2001 From: Santo Leto Date: Thu, 17 Oct 2024 14:24:45 +0000 Subject: [PATCH] Add new current topology panel --- .../MongoDB/MongoDB_Cluster_Summary.json | 654 +++++++++++++++++- 1 file changed, 629 insertions(+), 25 deletions(-) diff --git a/dashboards/MongoDB/MongoDB_Cluster_Summary.json b/dashboards/MongoDB/MongoDB_Cluster_Summary.json index cdae8309ac..a703128f6f 100644 --- a/dashboards/MongoDB/MongoDB_Cluster_Summary.json +++ b/dashboards/MongoDB/MongoDB_Cluster_Summary.json @@ -1032,7 +1032,8 @@ "mode": "absolute", "steps": [ { - "color": "green" + "color": "green", + "value": null } ] }, @@ -1194,7 +1195,8 @@ "mode": "absolute", "steps": [ { - "color": "green" + "color": "green", + "value": null } ] }, @@ -1375,7 +1377,8 @@ "mode": "absolute", "steps": [ { - "color": "green" + "color": "green", + "value": null } ] } @@ -1533,6 +1536,554 @@ "x": 0, "y": 39 }, + "id": 1302, + "panels": [], + "title": "Current Topology", + "type": "row" + }, + { + "colors": [ + "#299c46", + "#ED8128", + "#d44a3a", + "#4040a0" + ], + "description": "Config servers store the metadata for a sharded cluster. The metadata reflects state and organization for all data and components within the sharded cluster. The metadata includes the list of chunks on every shard and the ranges that define the chunks.", + "gridPos": { + "h": 5, + "w": 12, + "x": 0, + "y": 40 + }, + "id": 1306, + "libraryPanel": { + "description": "Config servers store the metadata for a sharded cluster. The metadata reflects state and organization for all data and components within the sharded cluster. The metadata includes the list of chunks on every shard and the ranges that define the chunks.", + "meta": { + "connectedDashboards": 1, + "created": "2024-10-17T12:43:59Z", + "createdBy": { + "avatarUrl": "/graph/avatar/46d229b033af06a191ff2267bca9ae56", + "id": 1, + "name": "admin" + }, + "folderName": "MongoDB", + "folderUid": "aHCJfygNk", + "updated": "2024-10-17T12:43:59Z", + "updatedBy": { + "avatarUrl": "/graph/avatar/46d229b033af06a191ff2267bca9ae56", + "id": 1, + "name": "admin" + } + }, + "name": "Config Servers", + "type": "grafana-polystat-panel", + "uid": "AsAKgAiHk", + "version": 1 + }, + "mappingType": 1, + "nullPointMode": "connected", + "pluginVersion": "9.2.20", + "polystat": { + "animationSpeed": 2500, + "columnAutoSize": true, + "columns": "", + "defaultClickThrough": "", + "defaultClickThroughNewTab": false, + "defaultClickThroughSanitize": false, + "displayLimit": 100, + "ellipseCharacters": 18, + "ellipseEnabled": false, + "fontAutoColor": true, + "fontAutoScale": true, + "fontSize": 12, + "fontType": "Roboto", + "globalDecimals": 0, + "globalDisplayMode": "all", + "globalDisplayTextTriggeredEmpty": "OK", + "globalOperatorName": "current", + "globalThresholds": [ + { + "color": "#299c46", + "state": 0, + "value": 1 + }, + { + "color": "#E0B400", + "state": 0, + "value": 2 + }, + { + "color": "#FA6400", + "state": 0, + "value": 7 + }, + { + "color": "#d44a3a", + "state": 2, + "value": 8 + } + ], + "globalUnitFormat": "short", + "gradientEnabled": true, + "hexagonSortByDirection": 1, + "hexagonSortByField": "name", + "maxMetrics": 0, + "polygonBorderColor": "#000000", + "polygonBorderSize": 2, + "polygonGlobalFillColor": "#0a55a1", + "radius": "", + "radiusAutoSize": true, + "regexPattern": "", + "rowAutoSize": true, + "rows": "", + "shape": "hexagon_pointed_top", + "tooltipDisplayMode": "all", + "tooltipDisplayTextTriggeredEmpty": "OK", + "tooltipEnabled": true, + "tooltipFontSize": 12, + "tooltipFontType": "Roboto", + "tooltipPrimarySortDirection": 2, + "tooltipPrimarySortField": "thresholdLevel", + "tooltipSecondarySortDirection": 2, + "tooltipSecondarySortField": "value", + "tooltipTimestampEnabled": true, + "valueEnabled": true + }, + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "repeatDirection": "v", + "savedComposites": [], + "savedOverrides": [], + "targets": [ + { + "editorMode": "code", + "exemplar": false, + "expr": "max by (service_name) (mongodb_mongod_replset_my_state{environment=~\"$environment\",cluster=~\"$cluster\",set!~\"$shard\",set!='',service_name=~\"$service_name\"})", + "hide": true, + "instant": true, + "legendFormat": "__auto", + "range": false, + "refId": "A" + }, + { + "editorMode": "code", + "exemplar": false, + "expr": "min by (member_idx) (mongodb_rs_members_state{environment=~\"$environment\",cluster=~\"$cluster\",rs_nm!~\"$shard\"})", + "hide": false, + "instant": true, + "legendFormat": "__auto", + "range": false, + "refId": "B" + } + ], + "title": "Config Servers", + "transformations": [], + "type": "grafana-polystat-panel", + "valueMaps": [ + { + "op": "=", + "text": "PRIMARY", + "value": "1" + }, + { + "op": "=", + "text": "SECONDARY", + "value": "2" + }, + { + "op": "=", + "text": "ARBITER", + "value": "7" + }, + { + "op": "=", + "text": "DOWN", + "value": "8" + }, + { + "op": "=", + "text": "Exporter is not connected", + "value": "null" + }, + { + "op": "=", + "text": "RECOVERING", + "value": "3" + }, + { + "op": "=", + "text": "STARTUP2", + "value": "5" + }, + { + "op": "=", + "text": "UNKNOWN", + "value": "6" + }, + { + "op": "=", + "text": "ROLLBACK", + "value": "9" + }, + { + "op": "=", + "text": "REMOVED", + "value": "10" + }, + { + "op": "=", + "text": "STARTUP", + "value": "0" + } + ] + }, + { + "colors": [ + "#299c46", + "rgba(237, 129, 40, 0.89)", + "#d44a3a", + "#4040a0" + ], + "description": "Mongos is a routing service for MongoDB shard configurations that processes queries from the application layer, and determines the location of this data in the sharded cluster, in order to complete these operations. From the perspective of the application, a mongos instance behaves identically to any other MongoDB instance.", + "gridPos": { + "h": 5, + "w": 12, + "x": 12, + "y": 40 + }, + "id": 1308, + "libraryPanel": { + "description": "Mongos is a routing service for MongoDB shard configurations that processes queries from the application layer, and determines the location of this data in the sharded cluster, in order to complete these operations. From the perspective of the application, a mongos instance behaves identically to any other MongoDB instance.", + "meta": { + "connectedDashboards": 1, + "created": "2024-10-17T12:44:14Z", + "createdBy": { + "avatarUrl": "/graph/avatar/46d229b033af06a191ff2267bca9ae56", + "id": 1, + "name": "admin" + }, + "folderName": "MongoDB", + "folderUid": "aHCJfygNk", + "updated": "2024-10-17T13:32:09Z", + "updatedBy": { + "avatarUrl": "/graph/avatar/46d229b033af06a191ff2267bca9ae56", + "id": 1, + "name": "admin" + } + }, + "name": "Mongos Routers", + "type": "grafana-polystat-panel", + "uid": "VMR5RAiHk", + "version": 5 + }, + "mappingType": 1, + "mappingTypes": [ + { + "name": "value to text", + "value": 1 + }, + { + "name": "range to text", + "value": 2 + } + ], + "nullPointMode": "connected", + "polystat": { + "animationSpeed": 2500, + "columnAutoSize": true, + "columns": "", + "defaultClickThrough": "/graph/d/mongodb-instance-summary/mongodb-instance-summary?from=$__from&to=$__to&var-service_name=${__cell_name}", + "defaultClickThroughNewTab": true, + "defaultClickThroughSanitize": true, + "displayLimit": 100, + "ellipseCharacters": 18, + "ellipseEnabled": false, + "fontAutoColor": true, + "fontAutoScale": true, + "fontSize": 12, + "fontType": "Roboto", + "globalDecimals": 0, + "globalDisplayMode": "all", + "globalDisplayTextTriggeredEmpty": "OK", + "globalOperatorName": "current", + "globalThresholds": [ + { + "color": "#d44a3a", + "state": 2, + "value": 0 + }, + { + "color": "#299c46", + "state": 0, + "value": 1 + } + ], + "globalUnitFormat": "ops", + "gradientEnabled": true, + "hexagonSortByDirection": 1, + "hexagonSortByField": "name", + "maxMetrics": 0, + "polygonBorderColor": "black", + "polygonBorderSize": 2, + "polygonGlobalFillColor": "#8AB8FF", + "radius": "", + "radiusAutoSize": true, + "regexPattern": "", + "rowAutoSize": true, + "rows": "", + "shape": "hexagon_pointed_top", + "tooltipDisplayMode": "all", + "tooltipDisplayTextTriggeredEmpty": "OK", + "tooltipEnabled": true, + "tooltipFontSize": 12, + "tooltipFontType": "Roboto", + "tooltipPrimarySortDirection": 2, + "tooltipPrimarySortField": "thresholdLevel", + "tooltipSecondarySortDirection": 2, + "tooltipSecondarySortField": "name", + "tooltipTimestampEnabled": true, + "valueEnabled": true + }, + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "repeatDirection": "v", + "savedComposites": [], + "savedOverrides": [], + "targets": [ + { + "editorMode": "code", + "exemplar": false, + "expr": "max by (service_name) (mongodb_up{environment=~\"$environment\", cluster=~\"$cluster\", service_name=~\"$service_name_mongos\"})", + "hide": false, + "instant": true, + "legendFormat": "__auto", + "range": false, + "refId": "B" + } + ], + "title": "Mongos Routers", + "type": "grafana-polystat-panel", + "valueMaps": [ + { + "op": "=", + "text": "DOWN", + "value": "0" + }, + { + "op": "=", + "text": "UP", + "value": "1" + } + ] + }, + { + "colors": [ + "#299c46", + "#ED8128", + "#d44a3a", + "#4040a0" + ], + "description": "A shard contains a subset of sharded data for a sharded cluster. Together, the cluster’s shards hold the entire data set for the cluster.", + "gridPos": { + "h": 5, + "w": 11, + "x": 7, + "y": 45 + }, + "id": 1310, + "libraryPanel": { + "description": "A shard contains a subset of sharded data for a sharded cluster. Together, the cluster’s shards hold the entire data set for the cluster.", + "meta": { + "connectedDashboards": 1, + "created": "2024-10-17T12:44:24Z", + "createdBy": { + "avatarUrl": "/graph/avatar/46d229b033af06a191ff2267bca9ae56", + "id": 1, + "name": "admin" + }, + "folderName": "MongoDB", + "folderUid": "aHCJfygNk", + "updated": "2024-10-17T12:44:24Z", + "updatedBy": { + "avatarUrl": "/graph/avatar/46d229b033af06a191ff2267bca9ae56", + "id": 1, + "name": "admin" + } + }, + "name": "Shard - $shard", + "type": "grafana-polystat-panel", + "uid": "ysDcRAmHk", + "version": 1 + }, + "mappingType": 1, + "nullPointMode": "connected", + "pluginVersion": "9.2.20", + "polystat": { + "animationSpeed": 2500, + "columnAutoSize": true, + "columns": "", + "defaultClickThrough": "", + "defaultClickThroughNewTab": false, + "defaultClickThroughSanitize": false, + "displayLimit": 100, + "ellipseCharacters": 18, + "ellipseEnabled": false, + "fontAutoColor": true, + "fontAutoScale": true, + "fontSize": 12, + "fontType": "Roboto", + "globalDecimals": 0, + "globalDisplayMode": "all", + "globalDisplayTextTriggeredEmpty": "OK", + "globalOperatorName": "current", + "globalThresholds": [ + { + "color": "#37872D", + "state": 0, + "value": 1 + }, + { + "color": "#E0B400", + "state": 0, + "value": 2 + }, + { + "color": "#8b8000", + "state": 0, + "value": 7 + }, + { + "color": "#d44a3a", + "state": 2, + "value": 8 + } + ], + "globalUnitFormat": "short", + "gradientEnabled": true, + "hexagonSortByDirection": 3, + "hexagonSortByField": "value", + "maxMetrics": 0, + "polygonBorderColor": "#000000", + "polygonBorderSize": 2, + "polygonGlobalFillColor": "#0a55a1", + "radius": "", + "radiusAutoSize": true, + "regexPattern": "", + "rowAutoSize": true, + "rows": "", + "shape": "hexagon_pointed_top", + "tooltipDisplayMode": "all", + "tooltipDisplayTextTriggeredEmpty": "OK", + "tooltipEnabled": true, + "tooltipFontSize": 12, + "tooltipFontType": "Roboto", + "tooltipPrimarySortDirection": 2, + "tooltipPrimarySortField": "thresholdLevel", + "tooltipSecondarySortDirection": 2, + "tooltipSecondarySortField": "value", + "tooltipTimestampEnabled": true, + "valueEnabled": true + }, + "rangeMaps": [ + { + "from": "null", + "text": "N/A", + "to": "null" + } + ], + "repeat": "shard", + "repeatDirection": "v", + "savedComposites": [], + "savedOverrides": [], + "targets": [ + { + "editorMode": "code", + "expr": "min by (member_idx) (mongodb_rs_members_state{environment=~\"$environment\",cluster=~\"$cluster\",rs_nm=~\"$shard\"})", + "hide": false, + "legendFormat": "__auto", + "range": true, + "refId": "B" + } + ], + "title": "Shard - $shard", + "transformations": [], + "type": "grafana-polystat-panel", + "valueMaps": [ + { + "op": "=", + "text": "PRIMARY", + "value": "1" + }, + { + "op": "=", + "text": "SECONDARY", + "value": "2" + }, + { + "op": "=", + "text": "ARBITER", + "value": "7" + }, + { + "op": "=", + "text": "DOWN", + "value": "8" + }, + { + "op": "=", + "text": "UNKNOWN", + "value": "6" + }, + { + "op": "=", + "text": "REMOVED", + "value": "10" + }, + { + "op": "=", + "text": "ROLLBACK", + "value": "9" + }, + { + "op": "=", + "text": "STARTUP2", + "value": "5" + }, + { + "op": "=", + "text": "RECOVERING", + "value": "3" + }, + { + "op": "=", + "text": "STARTUP", + "value": "0" + }, + { + "op": "=", + "text": "Exporter is not connected", + "value": "null" + } + ] + }, + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 55 + }, "id": 1285, "panels": [], "title": "Node States", @@ -1618,7 +2169,8 @@ "mode": "absolute", "steps": [ { - "color": "green" + "color": "green", + "value": null }, { "color": "red", @@ -1634,7 +2186,7 @@ "h": 7, "w": 8, "x": 0, - "y": 40 + "y": 56 }, "id": 1281, "options": { @@ -1675,7 +2227,7 @@ "h": 1, "w": 24, "x": 0, - "y": 47 + "y": 63 }, "id": 1279, "panels": [], @@ -1714,7 +2266,8 @@ "mode": "absolute", "steps": [ { - "color": "red" + "color": "red", + "value": null } ] }, @@ -1739,7 +2292,7 @@ "h": 8, "w": 11, "x": 0, - "y": 48 + "y": 64 }, "hide_headers": false, "id": 1030, @@ -1888,7 +2441,8 @@ "mode": "absolute", "steps": [ { - "color": "red" + "color": "red", + "value": null } ] } @@ -1899,7 +2453,7 @@ "h": 8, "w": 13, "x": 11, - "y": 48 + "y": 64 }, "id": 1043, "options": { @@ -1968,7 +2522,7 @@ "h": 1, "w": 24, "x": 0, - "y": 56 + "y": 72 }, "id": 81, "panels": [], @@ -2002,7 +2556,7 @@ "h": 7, "w": 24, "x": 0, - "y": 57 + "y": 73 }, "hiddenSeries": false, "id": 37, @@ -2115,7 +2669,7 @@ "h": 7, "w": 24, "x": 0, - "y": 64 + "y": 80 }, "hiddenSeries": false, "id": 1177, @@ -2201,7 +2755,7 @@ "h": 1, "w": 24, "x": 0, - "y": 71 + "y": 87 }, "id": 1199, "panels": [], @@ -2229,7 +2783,8 @@ "mode": "absolute", "steps": [ { - "color": "red" + "color": "red", + "value": null } ] } @@ -2258,7 +2813,7 @@ "h": 8, "w": 6, "x": 0, - "y": 72 + "y": 88 }, "hide_headers": false, "id": 1200, @@ -2334,7 +2889,7 @@ "h": 8, "w": 18, "x": 6, - "y": 72 + "y": 88 }, "hiddenSeries": false, "id": 1201, @@ -2426,7 +2981,7 @@ "h": 7, "w": 24, "x": 0, - "y": 80 + "y": 96 }, "hiddenSeries": false, "id": 1216, @@ -2518,7 +3073,7 @@ "h": 7, "w": 24, "x": 0, - "y": 87 + "y": 103 }, "hiddenSeries": false, "id": 1212, @@ -2597,7 +3152,7 @@ "h": 1, "w": 24, "x": 0, - "y": 94 + "y": 110 }, "id": 97, "panels": [], @@ -2630,7 +3185,7 @@ "h": 8, "w": 12, "x": 0, - "y": 95 + "y": 111 }, "hiddenSeries": false, "id": 14, @@ -2734,7 +3289,7 @@ "h": 8, "w": 12, "x": 12, - "y": 95 + "y": 111 }, "hiddenSeries": false, "id": 27, @@ -2890,9 +3445,13 @@ }, { "current": { - "selected": false, - "text": "All", - "value": "$__all" + "selected": true, + "text": [ + "All" + ], + "value": [ + "$__all" + ] }, "definition": "label_values({__name__=~\"pg_up|mysql_up|mongodb_up|proxysql_mysql_status_active_transactions\"}, environment)", "hide": 0, @@ -3021,6 +3580,51 @@ "tagsQuery": "", "type": "query", "useTags": false + }, + { + "current": { + "selected": false, + "text": "All", + "value": "$__all" + }, + "definition": "label_values(mongodb_mongos_sharding_shards_total{environment=~\"$environment\",cluster=~\"$cluster\"}, service_name)", + "hide": 2, + "includeAll": true, + "label": "Node", + "multi": true, + "name": "service_name_mongos", + "options": [], + "query": { + "query": "label_values(mongodb_mongos_sharding_shards_total{environment=~\"$environment\",cluster=~\"$cluster\"}, service_name)", + "refId": "StandardVariableQuery" + }, + "refresh": 2, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" + }, + { + "current": { + "selected": false, + "text": "arbiter", + "value": "arbiter" + }, + "definition": "label_values(mongodb_up, cluster_role)", + "hide": 2, + "includeAll": false, + "multi": false, + "name": "cluster_role", + "options": [], + "query": { + "query": "label_values(mongodb_up, cluster_role)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" } ] },