You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by zy...@apache.org on 2023/03/21 00:36:03 UTC
[iotdb] branch master updated: [IOTDB-5675] Metric of Schema Template (#9390)
This is an automated email from the ASF dual-hosted git repository.
zyk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git
The following commit(s) were added to refs/heads/master by this push:
new 94ac27b57f [IOTDB-5675] Metric of Schema Template (#9390)
94ac27b57f is described below
commit 94ac27b57fb6fdf68bc77e9fcfdd0e848a8a300e
Author: Chen YZ <43...@users.noreply.github.com>
AuthorDate: Tue Mar 21 08:35:55 2023 +0800
[IOTDB-5675] Metric of Schema Template (#9390)
---
.../Apache-IoTDB-DataNode-Dashboard.json | 3900 +++++++++++---------
docs/UserGuide/Monitor-Alert/Metric-Tool.md | 22 +-
docs/zh/UserGuide/Monitor-Alert/Metric-Tool.md | 19 +-
.../db/metadata/metric/SchemaEngineMemMetric.java | 16 +-
.../db/metadata/metric/SchemaRegionMemMetric.java | 34 +
.../db/metadata/mtree/MTreeBelowSGCachedImpl.java | 28 +-
.../db/metadata/mtree/MTreeBelowSGMemoryImpl.java | 15 +-
.../mtree/snapshot/MemMTreeSnapshotUtil.java | 12 +-
.../db/metadata/mtree/store/MemMTreeStore.java | 4 +-
.../metadata/rescon/ISchemaEngineStatistics.java | 2 +
.../metadata/rescon/ISchemaRegionStatistics.java | 4 +
.../metadata/rescon/MemSchemaEngineStatistics.java | 26 +-
.../metadata/rescon/MemSchemaRegionStatistics.java | 36 +-
.../schemaregion/SchemaRegionMemoryImpl.java | 5 +
.../schemaregion/SchemaRegionSchemaFileImpl.java | 5 +
.../metadata/template/ClusterTemplateManager.java | 7 +
.../iotdb/db/metadata/template/Template.java | 4 +
.../schemaRegion/SchemaStatisticsTest.java | 86 +
18 files changed, 2422 insertions(+), 1803 deletions(-)
diff --git a/docs/UserGuide/Monitor-Alert/Apache-IoTDB-DataNode-Dashboard.json b/docs/UserGuide/Monitor-Alert/Apache-IoTDB-DataNode-Dashboard.json
index 3fe91a438a..60f5725a00 100644
--- a/docs/UserGuide/Monitor-Alert/Apache-IoTDB-DataNode-Dashboard.json
+++ b/docs/UserGuide/Monitor-Alert/Apache-IoTDB-DataNode-Dashboard.json
@@ -11,11 +11,23 @@
],
"__elements": {},
"__requires": [
+ {
+ "type": "panel",
+ "id": "bargauge",
+ "name": "Bar gauge",
+ "version": ""
+ },
{
"type": "grafana",
"id": "grafana",
"name": "Grafana",
- "version": "9.3.6"
+ "version": "9.3.1"
+ },
+ {
+ "type": "panel",
+ "id": "piechart",
+ "name": "Pie chart",
+ "version": ""
},
{
"type": "datasource",
@@ -91,6 +103,8 @@
"mode": "palette-classic"
},
"custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
@@ -123,7 +137,8 @@
"mode": "absolute",
"steps": [
{
- "color": "green"
+ "color": "green",
+ "value": null
}
]
}
@@ -134,7 +149,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 1
+ "y": 65
},
"id": 2,
"options": {
@@ -178,6 +193,8 @@
"mode": "palette-classic"
},
"custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
@@ -210,7 +227,8 @@
"mode": "absolute",
"steps": [
{
- "color": "green"
+ "color": "green",
+ "value": null
}
]
}
@@ -221,7 +239,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 1
+ "y": 65
},
"id": 3,
"options": {
@@ -265,6 +283,8 @@
"mode": "palette-classic"
},
"custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
@@ -297,7 +317,8 @@
"mode": "absolute",
"steps": [
{
- "color": "green"
+ "color": "green",
+ "value": null
}
]
},
@@ -309,7 +330,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 1
+ "y": 65
},
"id": 4,
"options": {
@@ -424,7 +445,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 10
+ "y": 74
},
"id": 6,
"options": {
@@ -511,7 +532,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 10
+ "y": 74
},
"id": 55,
"options": {
@@ -598,7 +619,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 10
+ "y": 74
},
"id": 56,
"options": {
@@ -685,7 +706,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 18
+ "y": 82
},
"id": 9,
"options": {
@@ -773,7 +794,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 18
+ "y": 82
},
"id": 10,
"options": {
@@ -863,7 +884,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 18
+ "y": 82
},
"id": 11,
"options": {
@@ -963,7 +984,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 26
+ "y": 90
},
"id": 12,
"options": {
@@ -1051,7 +1072,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 26
+ "y": 90
},
"id": 13,
"options": {
@@ -1167,7 +1188,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 4
+ "y": 68
},
"id": 15,
"options": {
@@ -1257,7 +1278,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 4
+ "y": 68
},
"id": 16,
"options": {
@@ -1347,7 +1368,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 12
+ "y": 76
},
"id": 17,
"options": {
@@ -1449,7 +1470,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 12
+ "y": 76
},
"id": 18,
"options": {
@@ -1539,7 +1560,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 12
+ "y": 76
},
"id": 19,
"options": {
@@ -1656,7 +1677,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 20
+ "y": 84
},
"id": 169,
"options": {
@@ -1779,7 +1800,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 20
+ "y": 84
},
"id": 171,
"options": {
@@ -1894,7 +1915,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 204
+ "y": 268
},
"id": 80,
"options": {
@@ -1982,7 +2003,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 204
+ "y": 268
},
"id": 60,
"options": {
@@ -2070,7 +2091,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 204
+ "y": 268
},
"id": 61,
"options": {
@@ -2158,7 +2179,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 204
+ "y": 268
},
"id": 62,
"options": {
@@ -2246,7 +2267,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 212
+ "y": 276
},
"id": 63,
"options": {
@@ -2334,7 +2355,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 212
+ "y": 276
},
"id": 81,
"options": {
@@ -2422,7 +2443,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 212
+ "y": 276
},
"id": 64,
"options": {
@@ -2510,7 +2531,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 212
+ "y": 276
},
"id": 65,
"options": {
@@ -2598,7 +2619,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 220
+ "y": 284
},
"id": 83,
"options": {
@@ -2686,7 +2707,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 220
+ "y": 284
},
"id": 66,
"options": {
@@ -2774,7 +2795,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 220
+ "y": 284
},
"id": 67,
"options": {
@@ -2862,7 +2883,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 220
+ "y": 284
},
"id": 68,
"options": {
@@ -2950,7 +2971,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 228
+ "y": 292
},
"id": 82,
"options": {
@@ -3038,7 +3059,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 228
+ "y": 292
},
"id": 69,
"options": {
@@ -3126,7 +3147,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 228
+ "y": 292
},
"id": 70,
"options": {
@@ -3214,7 +3235,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 228
+ "y": 292
},
"id": 71,
"options": {
@@ -3302,7 +3323,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 236
+ "y": 300
},
"id": 72,
"options": {
@@ -3390,7 +3411,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 236
+ "y": 300
},
"id": 84,
"options": {
@@ -3478,7 +3499,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 236
+ "y": 300
},
"id": 73,
"options": {
@@ -3566,7 +3587,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 236
+ "y": 300
},
"id": 74,
"options": {
@@ -3654,7 +3675,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 244
+ "y": 308
},
"id": 131,
"options": {
@@ -3743,7 +3764,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 244
+ "y": 308
},
"id": 132,
"options": {
@@ -3832,7 +3853,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 244
+ "y": 308
},
"id": 133,
"options": {
@@ -3922,7 +3943,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 244
+ "y": 308
},
"id": 134,
"options": {
@@ -4011,7 +4032,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 252
+ "y": 316
},
"id": 76,
"options": {
@@ -4099,7 +4120,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 252
+ "y": 316
},
"id": 128,
"options": {
@@ -4187,7 +4208,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 252
+ "y": 316
},
"id": 129,
"options": {
@@ -4275,7 +4296,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 252
+ "y": 316
},
"id": 130,
"options": {
@@ -4363,7 +4384,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 260
+ "y": 324
},
"id": 135,
"options": {
@@ -4451,7 +4472,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 260
+ "y": 324
},
"id": 136,
"options": {
@@ -4539,7 +4560,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 260
+ "y": 324
},
"id": 137,
"options": {
@@ -4627,7 +4648,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 260
+ "y": 324
},
"id": 138,
"options": {
@@ -4715,7 +4736,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 268
+ "y": 332
},
"id": 139,
"options": {
@@ -4803,7 +4824,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 268
+ "y": 332
},
"id": 140,
"options": {
@@ -4891,7 +4912,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 268
+ "y": 332
},
"id": 167,
"options": {
@@ -4980,7 +5001,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 276
+ "y": 340
},
"id": 163,
"options": {
@@ -5069,7 +5090,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 276
+ "y": 340
},
"id": 164,
"options": {
@@ -5158,7 +5179,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 276
+ "y": 340
},
"id": 165,
"options": {
@@ -5247,7 +5268,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 276
+ "y": 340
},
"id": 166,
"options": {
@@ -5363,7 +5384,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 205
+ "y": 269
},
"id": 75,
"options": {
@@ -5451,7 +5472,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 205
+ "y": 269
},
"id": 85,
"options": {
@@ -5539,7 +5560,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 205
+ "y": 269
},
"id": 77,
"options": {
@@ -5627,7 +5648,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 205
+ "y": 269
},
"id": 78,
"options": {
@@ -5715,7 +5736,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 213
+ "y": 277
},
"id": 86,
"options": {
@@ -5803,7 +5824,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 213
+ "y": 277
},
"id": 87,
"options": {
@@ -5891,7 +5912,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 213
+ "y": 277
},
"id": 88,
"options": {
@@ -5979,7 +6000,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 213
+ "y": 277
},
"id": 89,
"options": {
@@ -6067,7 +6088,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 221
+ "y": 285
},
"id": 90,
"options": {
@@ -6155,7 +6176,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 221
+ "y": 285
},
"id": 91,
"options": {
@@ -6243,7 +6264,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 221
+ "y": 285
},
"id": 92,
"options": {
@@ -6331,7 +6352,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 221
+ "y": 285
},
"id": 93,
"options": {
@@ -6419,7 +6440,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 229
+ "y": 293
},
"id": 94,
"options": {
@@ -6507,7 +6528,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 229
+ "y": 293
},
"id": 95,
"options": {
@@ -6595,7 +6616,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 229
+ "y": 293
},
"id": 96,
"options": {
@@ -6683,7 +6704,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 229
+ "y": 293
},
"id": 97,
"options": {
@@ -6771,7 +6792,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 237
+ "y": 301
},
"id": 98,
"options": {
@@ -6860,7 +6881,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 237
+ "y": 301
},
"id": 101,
"options": {
@@ -6949,7 +6970,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 237
+ "y": 301
},
"id": 102,
"options": {
@@ -7038,7 +7059,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 237
+ "y": 301
},
"id": 103,
"options": {
@@ -7126,7 +7147,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 245
+ "y": 309
},
"id": 104,
"options": {
@@ -7215,7 +7236,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 245
+ "y": 309
},
"id": 105,
"options": {
@@ -7304,7 +7325,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 245
+ "y": 309
},
"id": 106,
"options": {
@@ -7393,7 +7414,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 245
+ "y": 309
},
"id": 107,
"options": {
@@ -7481,7 +7502,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 253
+ "y": 317
},
"id": 108,
"options": {
@@ -7570,7 +7591,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 253
+ "y": 317
},
"id": 109,
"options": {
@@ -7659,7 +7680,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 253
+ "y": 317
},
"id": 110,
"options": {
@@ -7748,7 +7769,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 253
+ "y": 317
},
"id": 111,
"options": {
@@ -7834,7 +7855,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 261
+ "y": 325
},
"id": 112,
"options": {
@@ -7921,7 +7942,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 261
+ "y": 325
},
"id": 113,
"options": {
@@ -8008,7 +8029,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 261
+ "y": 325
},
"id": 114,
"options": {
@@ -8095,7 +8116,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 261
+ "y": 325
},
"id": 115,
"options": {
@@ -8181,7 +8202,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 269
+ "y": 333
},
"id": 116,
"options": {
@@ -8268,7 +8289,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 269
+ "y": 333
},
"id": 117,
"options": {
@@ -8355,7 +8376,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 269
+ "y": 333
},
"id": 118,
"options": {
@@ -8442,7 +8463,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 269
+ "y": 333
},
"id": 119,
"options": {
@@ -8528,7 +8549,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 277
+ "y": 341
},
"id": 120,
"options": {
@@ -8615,7 +8636,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 277
+ "y": 341
},
"id": 121,
"options": {
@@ -8702,7 +8723,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 277
+ "y": 341
},
"id": 122,
"options": {
@@ -8789,7 +8810,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 277
+ "y": 341
},
"id": 123,
"options": {
@@ -8875,7 +8896,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 285
+ "y": 349
},
"id": 124,
"options": {
@@ -8962,7 +8983,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 285
+ "y": 349
},
"id": 125,
"options": {
@@ -9049,7 +9070,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 285
+ "y": 349
},
"id": 126,
"options": {
@@ -9136,7 +9157,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 285
+ "y": 349
},
"id": 127,
"options": {
@@ -9251,7 +9272,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 206
+ "y": 270
},
"id": 143,
"options": {
@@ -9339,7 +9360,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 206
+ "y": 270
},
"id": 144,
"options": {
@@ -9427,7 +9448,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 206
+ "y": 270
},
"id": 145,
"options": {
@@ -9515,7 +9536,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 206
+ "y": 270
},
"id": 146,
"options": {
@@ -9603,7 +9624,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 214
+ "y": 278
},
"id": 147,
"options": {
@@ -9691,7 +9712,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 214
+ "y": 278
},
"id": 148,
"options": {
@@ -9779,7 +9800,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 214
+ "y": 278
},
"id": 149,
"options": {
@@ -9867,7 +9888,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 214
+ "y": 278
},
"id": 150,
"options": {
@@ -9955,7 +9976,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 222
+ "y": 286
},
"id": 151,
"options": {
@@ -10043,7 +10064,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 222
+ "y": 286
},
"id": 152,
"options": {
@@ -10131,7 +10152,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 222
+ "y": 286
},
"id": 153,
"options": {
@@ -10219,7 +10240,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 222
+ "y": 286
},
"id": 154,
"options": {
@@ -10307,7 +10328,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 230
+ "y": 294
},
"id": 155,
"options": {
@@ -10395,7 +10416,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 230
+ "y": 294
},
"id": 156,
"options": {
@@ -10483,7 +10504,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 230
+ "y": 294
},
"id": 157,
"options": {
@@ -10571,7 +10592,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 230
+ "y": 294
},
"id": 158,
"options": {
@@ -10659,7 +10680,7 @@
"h": 8,
"w": 6,
"x": 0,
- "y": 238
+ "y": 302
},
"id": 159,
"options": {
@@ -10747,7 +10768,7 @@
"h": 8,
"w": 6,
"x": 6,
- "y": 238
+ "y": 302
},
"id": 160,
"options": {
@@ -10835,7 +10856,7 @@
"h": 8,
"w": 6,
"x": 12,
- "y": 238
+ "y": 302
},
"id": 161,
"options": {
@@ -10923,7 +10944,7 @@
"h": 8,
"w": 6,
"x": 18,
- "y": 238
+ "y": 302
},
"id": 162,
"options": {
@@ -11036,7 +11057,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 7
+ "y": 71
},
"id": 21,
"options": {
@@ -11152,7 +11173,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 7
+ "y": 71
},
"id": 22,
"options": {
@@ -11241,7 +11262,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 7
+ "y": 71
},
"id": 23,
"options": {
@@ -11345,7 +11366,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 15
+ "y": 79
},
"id": 24,
"options": {
@@ -11464,7 +11485,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 15
+ "y": 79
},
"id": 25,
"options": {
@@ -11578,7 +11599,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 15
+ "y": 79
},
"id": 26,
"options": {
@@ -11666,7 +11687,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 23
+ "y": 87
},
"id": 27,
"options": {
@@ -11754,7 +11775,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 23
+ "y": 87
},
"id": 175,
"options": {
@@ -11842,7 +11863,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 23
+ "y": 87
},
"id": 29,
"options": {
@@ -11931,7 +11952,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 31
+ "y": 95
},
"id": 30,
"options": {
@@ -12022,7 +12043,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 31
+ "y": 95
},
"id": 31,
"options": {
@@ -12114,7 +12135,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 31
+ "y": 95
},
"id": 32,
"options": {
@@ -12205,7 +12226,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 39
+ "y": 103
},
"id": 28,
"options": {
@@ -12293,7 +12314,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 39
+ "y": 103
},
"id": 173,
"options": {
@@ -12419,8 +12440,7 @@
"mode": "absolute",
"steps": [
{
- "color": "green",
- "value": null
+ "color": "green"
},
{
"color": "red",
@@ -12436,7 +12456,7 @@
"h": 9,
"w": 12,
"x": 0,
- "y": 8
+ "y": 72
},
"id": 288,
"options": {
@@ -12572,8 +12592,7 @@
"mode": "absolute",
"steps": [
{
- "color": "green",
- "value": null
+ "color": "green"
},
{
"color": "red",
@@ -12589,7 +12608,7 @@
"h": 9,
"w": 12,
"x": 12,
- "y": 8
+ "y": 72
},
"id": 285,
"options": {
@@ -12724,8 +12743,7 @@
"mode": "absolute",
"steps": [
{
- "color": "green",
- "value": null
+ "color": "green"
},
{
"color": "red",
@@ -12741,7 +12759,7 @@
"h": 9,
"w": 8,
"x": 0,
- "y": 17
+ "y": 81
},
"id": 291,
"options": {
@@ -12853,8 +12871,7 @@
"mode": "absolute",
"steps": [
{
- "color": "green",
- "value": null
+ "color": "green"
},
{
"color": "red",
@@ -12870,7 +12887,7 @@
"h": 9,
"w": 8,
"x": 8,
- "y": 17
+ "y": 81
},
"id": 292,
"options": {
@@ -12961,8 +12978,7 @@
"mode": "absolute",
"steps": [
{
- "color": "green",
- "value": null
+ "color": "green"
},
{
"color": "red",
@@ -12978,7 +12994,7 @@
"h": 9,
"w": 8,
"x": 16,
- "y": 17
+ "y": 81
},
"id": 290,
"options": {
@@ -13130,7 +13146,7 @@
"h": 9,
"w": 12,
"x": 0,
- "y": 9
+ "y": 73
},
"id": 295,
"options": {
@@ -13280,7 +13296,7 @@
"h": 9,
"w": 12,
"x": 12,
- "y": 9
+ "y": 73
},
"id": 296,
"options": {
@@ -13429,7 +13445,7 @@
"h": 9,
"w": 8,
"x": 0,
- "y": 18
+ "y": 82
},
"id": 297,
"options": {
@@ -13555,7 +13571,7 @@
"h": 9,
"w": 8,
"x": 8,
- "y": 18
+ "y": 82
},
"id": 300,
"options": {
@@ -13660,7 +13676,7 @@
"h": 9,
"w": 8,
"x": 16,
- "y": 18
+ "y": 82
},
"id": 299,
"options": {
@@ -13757,7 +13773,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 17
+ "y": 81
},
"id": 34,
"options": {
@@ -13852,7 +13868,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 17
+ "y": 81
},
"id": 35,
"options": {
@@ -13956,7 +13972,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 17
+ "y": 81
},
"id": 40,
"options": {
@@ -14048,7 +14064,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 25
+ "y": 89
},
"id": 41,
"options": {
@@ -14164,7 +14180,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 25
+ "y": 89
},
"id": 42,
"options": {
@@ -14268,7 +14284,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 25
+ "y": 89
},
"id": 43,
"options": {
@@ -14382,7 +14398,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 33
+ "y": 97
},
"id": 44,
"options": {
@@ -14506,7 +14522,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 33
+ "y": 97
},
"id": 45,
"options": {
@@ -14607,7 +14623,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 33
+ "y": 97
},
"id": 46,
"options": {
@@ -14710,7 +14726,7 @@
"h": 7,
"w": 8,
"x": 0,
- "y": 41
+ "y": 105
},
"id": 47,
"options": {
@@ -14812,7 +14828,7 @@
"h": 7,
"w": 8,
"x": 8,
- "y": 41
+ "y": 105
},
"id": 48,
"options": {
@@ -14911,7 +14927,7 @@
"h": 7,
"w": 8,
"x": 16,
- "y": 41
+ "y": 105
},
"id": 49,
"options": {
@@ -15011,7 +15027,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 48
+ "y": 112
},
"id": 50,
"options": {
@@ -15147,7 +15163,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 48
+ "y": 112
},
"id": 51,
"options": {
@@ -15281,7 +15297,7 @@
"h": 8,
"w": 8,
"x": 16,
- "y": 48
+ "y": 112
},
"id": 52,
"options": {
@@ -15372,7 +15388,7 @@
"h": 8,
"w": 8,
"x": 0,
- "y": 56
+ "y": 120
},
"id": 53,
"options": {
@@ -15463,7 +15479,7 @@
"h": 8,
"w": 8,
"x": 8,
- "y": 56
+ "y": 120
},
"id": 54,
"options": {
@@ -15522,7 +15538,7 @@
"type": "row"
},
{
- "collapsed": true,
+ "collapsed": false,
"datasource": {
"type": "prometheus",
"uid": "Ar7cRMx4z"
@@ -15534,1730 +15550,2071 @@
"y": 10
},
"id": 197,
- "panels": [
+ "panels": [],
+ "targets": [
{
"datasource": {
"type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ "uid": "Ar7cRMx4z"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [
- {
- "options": {
- "0": {
- "index": 0,
- "text": "Memory"
- },
- "1": {
- "index": 1,
- "text": "Schema_File"
- }
- },
- "type": "value"
+ "refId": "A"
+ }
+ ],
+ "title": "Schema Engine",
+ "type": "row"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [
+ {
+ "options": {
+ "0": {
+ "index": 0,
+ "text": "Memory"
+ },
+ "1": {
+ "index": 1,
+ "text": "Schema_File"
}
- ],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- }
- ]
},
- "unit": "none"
- },
- "overrides": []
+ "type": "value"
+ }
+ ],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
},
- "gridPos": {
- "h": 4,
- "w": 4,
- "x": 0,
- "y": 19
+ "unit": "none"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 4,
+ "w": 8,
+ "x": 0,
+ "y": 11
+ },
+ "id": 302,
+ "options": {
+ "colorMode": "none",
+ "graphMode": "none",
+ "justifyMode": "auto",
+ "orientation": "auto",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "textMode": "value"
+ },
+ "pluginVersion": "9.3.1",
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "id": 224,
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "auto",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "textMode": "value"
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "schema_engine{name=\"schema_engine_mode\",instance=~\"$instance\"}",
+ "instant": false,
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Schema Engine Mode",
+ "type": "stat"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
},
- "pluginVersion": "9.3.6",
- "targets": [
+ "mappings": [
{
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ "options": {
+ "0": {
+ "index": 0,
+ "text": "RatisConsensus"
+ },
+ "1": {
+ "index": 1,
+ "text": "SimpleConsensus"
+ }
},
- "editorMode": "code",
- "exemplar": false,
- "expr": "schema_engine{name=\"schema_engine_mode\",instance=~\"$instance\"}",
- "instant": false,
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
+ "type": "value"
}
],
- "title": "Schema Engine Mode",
- "type": "stat"
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "none"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 4,
+ "w": 8,
+ "x": 8,
+ "y": 11
+ },
+ "id": 304,
+ "options": {
+ "colorMode": "none",
+ "graphMode": "none",
+ "justifyMode": "auto",
+ "orientation": "auto",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
},
+ "textMode": "value"
+ },
+ "pluginVersion": "9.3.1",
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- }
- ]
- },
- "unit": "none"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 4,
- "x": 4,
- "y": 19
- },
- "id": 219,
- "options": {
- "colorMode": "value",
- "graphMode": "area",
- "justifyMode": "auto",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "textMode": "value"
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "schema_engine{name=\"schema_region_consensus\",instance=~\"$instance\"}",
+ "instant": false,
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Schema Consensus Protocol",
+ "type": "stat"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
},
- "pluginVersion": "9.3.6",
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "exemplar": false,
- "expr": "schema_engine{name=\"schema_region_number\",instance=~\"$instance\"}",
- "instant": false,
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
+ "unit": "none"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 4,
+ "w": 8,
+ "x": 16,
+ "y": 11
+ },
+ "id": 306,
+ "options": {
+ "colorMode": "none",
+ "graphMode": "none",
+ "justifyMode": "auto",
+ "orientation": "auto",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
],
- "title": "Schema Region Number",
- "type": "stat"
+ "fields": "",
+ "values": false
},
+ "textMode": "auto"
+ },
+ "pluginVersion": "9.3.1",
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "continuous-BlPu"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 4,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- }
- ]
- },
- "unit": "bytes"
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "schema_file_flush_threshold"
- },
- "properties": [
- {
- "id": "color",
- "value": {
- "fixedColor": "orange",
- "mode": "fixed"
- }
- },
- {
- "id": "custom.fillOpacity",
- "value": 0
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "schema_file_release_threshold"
- },
- "properties": [
- {
- "id": "color",
- "value": {
- "fixedColor": "yellow",
- "mode": "fixed"
- }
- },
- {
- "id": "custom.fillOpacity",
- "value": 0
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "schema_region_mem_capacity"
- },
- "properties": [
- {
- "id": "color",
- "value": {
- "fixedColor": "red",
- "mode": "fixed"
- }
- },
- {
- "id": "custom.fillOpacity",
- "value": 0
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 8,
- "w": 16,
- "x": 8,
- "y": 19
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "schema_engine{name=\"schema_region_number\",instance=~\"$instance\"}",
+ "instant": false,
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Schema Region Number",
+ "type": "stat"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
},
- "id": 217,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "right",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
+ "custom": {
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
}
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "schema_engine{name=~\"schema_region_total_mem_usage|schema_region_mem_capacity|schema_file_release_threshold|schema_file_flush_threshold|schema_file_pinned_mem|schema_file_unpinned_mem\",instance=~\"$instance\"}",
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
+ "mappings": [],
+ "unit": "none"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 8,
+ "w": 4,
+ "x": 0,
+ "y": 15
+ },
+ "id": 308,
+ "options": {
+ "displayLabels": [],
+ "legend": {
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true,
+ "values": []
+ },
+ "pieType": "pie",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
],
- "title": "Schema Region Memory Overview",
- "type": "timeseries"
+ "fields": "",
+ "values": false
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "pluginVersion": "9.3.1",
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [
- {
- "options": {
- "0": {
- "index": 0,
- "text": "RatisConsensus"
- },
- "1": {
- "index": 1,
- "text": "SimpleConsensus"
- }
- },
- "type": "value"
- }
- ],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- }
- ]
- },
- "unit": "none"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 4,
- "x": 0,
- "y": 23
- },
- "id": 225,
- "options": {
- "colorMode": "value",
- "graphMode": "none",
- "justifyMode": "auto",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "textMode": "value"
- },
- "pluginVersion": "9.3.6",
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "exemplar": false,
- "expr": "schema_engine{name=\"schema_region_consensus\",instance=~\"$instance\"}",
- "instant": false,
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Schema Consensus Protocol",
- "type": "stat"
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "sum(quantity{name=\"timeSeries\", instance=~\"$instance\"})-\nsum(quantity{name=\"template_series_cnt\", instance=~\"$instance\"})",
+ "format": "time_series",
+ "hide": false,
+ "instant": false,
+ "legendFormat": "Normal",
+ "range": true,
+ "refId": "A"
},
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- }
- ]
- },
- "unit": "none"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 4,
- "x": 4,
- "y": 23
- },
- "id": 222,
+ "editorMode": "code",
+ "expr": "quantity{name=\"template_series_cnt\", instance=~\"$instance\"}",
+ "hide": false,
+ "legendFormat": "Template",
+ "range": true,
+ "refId": "B"
+ }
+ ],
+ "title": "Series Type",
+ "transformations": [
+ {
+ "id": "calculateField",
"options": {
- "colorMode": "value",
- "graphMode": "area",
- "justifyMode": "auto",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "textMode": "value"
+ "alias": "normal series",
+ "binary": {
+ "left": "{__name__=\"quantity\", cluster=\"defaultCluster\", instance=\"localhost:9093\", job=\"datanode\", name=\"timeSeries\", nodeId=\"-1\", nodeType=\"DATANODE\"}",
+ "operator": "-",
+ "reducer": "sum",
+ "right": "{__name__=\"quantity\", cluster=\"defaultCluster\", instance=\"localhost:9093\", job=\"datanode\", name=\"template_series_num\", nodeId=\"-1\", nodeType=\"DATANODE\"}"
+ },
+ "mode": "binary",
+ "reduce": {
+ "reducer": "sum"
+ },
+ "replaceFields": false
+ }
+ }
+ ],
+ "type": "piechart"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
},
- "pluginVersion": "9.3.6",
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "exemplar": false,
- "expr": "quantity{name=\"timeSeries\",instance=~\"$instance\"}",
- "instant": false,
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
+ "unit": "none"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 4,
+ "w": 4,
+ "x": 4,
+ "y": 15
+ },
+ "id": 310,
+ "options": {
+ "colorMode": "value",
+ "graphMode": "area",
+ "justifyMode": "auto",
+ "orientation": "auto",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
],
- "title": "Time Series Number",
- "type": "stat"
+ "fields": "",
+ "values": false
},
+ "textMode": "value"
+ },
+ "pluginVersion": "9.3.1",
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "quantity{name=\"timeSeries\",instance=~\"$instance\"}",
+ "instant": false,
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Time Series Number",
+ "type": "stat"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "continuous-BlPu"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 4,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
+ },
+ "unit": "bytes"
+ },
+ "overrides": [
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "schema_file_flush_threshold"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "orange",
+ "mode": "fixed"
}
},
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "id": "custom.fillOpacity",
+ "value": 0
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 12,
- "x": 0,
- "y": 27
+ ]
},
- "id": 215,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "schema_file_release_threshold"
},
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "yellow",
+ "mode": "fixed"
+ }
+ },
+ {
+ "id": "custom.fillOpacity",
+ "value": 0
+ }
+ ]
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ {
+ "matcher": {
+ "id": "byName",
+ "options": "schema_region_mem_capacity"
+ },
+ "properties": [
+ {
+ "id": "color",
+ "value": {
+ "fixedColor": "red",
+ "mode": "fixed"
+ }
},
- "editorMode": "code",
- "expr": "schema_region{name=\"schema_region_series_cnt\",instance=~\"$instance\"}",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Timeseries Count per SchemaRegion",
- "type": "timeseries"
+ {
+ "id": "custom.fillOpacity",
+ "value": 0
+ }
+ ]
+ }
+ ]
+ },
+ "gridPos": {
+ "h": 8,
+ "w": 16,
+ "x": 8,
+ "y": 15
+ },
+ "id": 217,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "right",
+ "showLegend": true
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- },
- "unit": "bytes"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 12,
- "x": 12,
- "y": 27
+ "editorMode": "code",
+ "expr": "schema_engine{name=~\"schema_region_total_mem_usage|schema_region_mem_capacity|schema_file_release_threshold|schema_file_flush_threshold|schema_file_pinned_mem|schema_file_unpinned_mem\",instance=~\"$instance\"}",
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Schema Region Memory Overview",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ }
+ ]
},
- "id": 213,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
+ "unit": "none"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 4,
+ "w": 4,
+ "x": 4,
+ "y": 19
+ },
+ "id": 312,
+ "options": {
+ "colorMode": "value",
+ "graphMode": "area",
+ "justifyMode": "auto",
+ "orientation": "auto",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
+ ],
+ "fields": "",
+ "values": false
+ },
+ "textMode": "value"
+ },
+ "pluginVersion": "9.3.1",
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "quantity{name=\"template_series_cnt\",instance=~\"$instance\"}",
+ "instant": false,
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Template Series Number",
+ "type": "stat"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "description": "",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "editorMode": "code",
- "expr": "schema_region{name=\"schema_region_mem_usage\",instance=~\"$instance\"}",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Memory Usgae per SchemaRegion",
- "type": "timeseries"
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 12,
+ "x": 0,
+ "y": 23
+ },
+ "id": 215,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
+ "editorMode": "code",
+ "expr": "schema_region{name=\"schema_region_series_cnt\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Timeseries Count per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "color": "red",
+ "value": 80
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 0,
- "y": 34
+ ]
},
- "id": 199,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
+ "unit": "bytes"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 12,
+ "x": 12,
+ "y": 23
+ },
+ "id": 213,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ "editorMode": "code",
+ "expr": "schema_region{name=\"schema_region_mem_usage\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Memory Usgae per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "description": "",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "thresholds"
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "editorMode": "code",
- "exemplar": false,
- "expr": "schema_region{name=\"schema_file_pinned_num\",instance=~\"$instance\"}",
- "hide": false,
- "interval": "",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 12,
+ "x": 0,
+ "y": 30
+ },
+ "id": 316,
+ "options": {
+ "displayMode": "gradient",
+ "minVizHeight": 10,
+ "minVizWidth": 0,
+ "orientation": "auto",
+ "reduceOptions": {
+ "calcs": [
+ "lastNotNull"
],
- "title": "Pinned MNode per SchemaRegion",
- "type": "timeseries"
+ "fields": "",
+ "values": false
},
+ "showUnfilled": true
+ },
+ "pluginVersion": "9.3.1",
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ "editorMode": "code",
+ "expr": "schema_region{name=\"activated_template_cnt\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Activated Template Count per SchemaRegion",
+ "type": "bargauge"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "description": "",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "unit": "bytes"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 6,
- "y": 34
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 12,
+ "x": 12,
+ "y": 30
+ },
+ "id": 314,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "id": 203,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
+ "editorMode": "code",
+ "expr": "schema_region{name=\"template_series_cnt\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Template Series Count per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ },
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 0,
+ "y": 37
+ },
+ "id": 199,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ "editorMode": "code",
+ "exemplar": false,
+ "expr": "schema_region{name=\"schema_file_pinned_num\",instance=~\"$instance\"}",
+ "hide": false,
+ "interval": "",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Pinned MNode per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "editorMode": "code",
- "expr": "schema_region{name=\"schema_file_pinned_mem\",instance=~\"$instance\"}",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Pinned Memory per SchemaRegion",
- "type": "timeseries"
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ },
+ "unit": "bytes"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 6,
+ "y": 37
+ },
+ "id": 203,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
+ "editorMode": "code",
+ "expr": "schema_region{name=\"schema_file_pinned_mem\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Pinned Memory per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "color": "red",
+ "value": 80
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 12,
- "y": 34
- },
- "id": 209,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "schema_region{name=\"schema_file_cache_node_num\",instance=~\"$instance\"}",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Cache MNode per SchemaRegion",
- "type": "timeseries"
+ ]
+ }
},
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 18,
- "y": 34
- },
- "id": 211,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "schema_region{name=~\"schema_file_mlog_.*\",instance=~\"$instance\"}",
- "legendFormat": "{{name}}_{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "MLog Length and Checkpoint",
- "type": "timeseries"
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 12,
+ "y": 37
+ },
+ "id": 209,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
+ "editorMode": "code",
+ "expr": "schema_region{name=\"schema_file_cache_node_num\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Cache MNode per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "description": "",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "color": "red",
+ "value": 80
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 0,
- "y": 41
- },
- "id": 201,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "schema_region{name=\"schema_file_unpinned_num\",instance=~\"$instance\"}",
- "interval": "",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Unpinned MNode per SchemaRegion",
- "type": "timeseries"
- },
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- },
- "unit": "bytes"
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 6,
- "y": 41
- },
- "id": 205,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "schema_region{name=\"schema_file_unpinned_mem\",instance=~\"$instance\"}",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Unpinned Memory per SchemaRegion",
- "type": "timeseries"
+ ]
+ }
},
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 12,
- "y": 41
- },
- "id": 207,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "schema_region{name=\"schema_file_buffer_node_num\",instance=~\"$instance\"}",
- "legendFormat": "{{region}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Buffer MNode per SchemaRegion",
- "type": "timeseries"
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 18,
+ "y": 37
+ },
+ "id": 211,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 18,
- "y": 41
- },
- "id": 220,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ "editorMode": "code",
+ "expr": "schema_region{name=~\"schema_file_mlog_.*\",instance=~\"$instance\"}",
+ "legendFormat": "{{name}}_{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "MLog Length and Checkpoint",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "editorMode": "code",
- "expr": "schema_engine{name=~\"schema_file_pinned_num|schema_file_unpinned_num\",instance=~\"$instance\"}",
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Schema File Memory MNode Number",
- "type": "timeseries"
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
},
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 0,
+ "y": 44
+ },
+ "id": 201,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
+ "editorMode": "code",
+ "expr": "schema_region{name=\"schema_file_unpinned_num\",instance=~\"$instance\"}",
+ "interval": "",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Unpinned MNode per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "color": "red",
+ "value": 80
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 0,
- "y": 48
+ ]
},
- "id": 221,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
+ "unit": "bytes"
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 6,
+ "y": 44
+ },
+ "id": 205,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
+ "editorMode": "code",
+ "expr": "schema_region{name=\"schema_file_unpinned_mem\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Unpinned Memory per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "editorMode": "code",
- "expr": "schema_engine{name=~\"schema_file_flush_thread_num|schema_file_release_thread_num\",instance=~\"$instance\"}",
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Release and Flush Thread Number",
- "type": "timeseries"
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 12,
+ "y": 44
+ },
+ "id": 207,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
+ "editorMode": "code",
+ "expr": "schema_region{name=\"schema_file_buffer_node_num\",instance=~\"$instance\"}",
+ "legendFormat": "{{region}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Buffer MNode per SchemaRegion",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "color": "red",
+ "value": 80
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 6,
- "y": 48
- },
- "id": 223,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 18,
+ "y": 44
+ },
+ "id": 220,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "rate(schema_engine_seconds_count{name=~\"schema_file_release|schema_file_flush\",instance=~\"$instance\"}[1m])",
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Release and Flush MNode Rate",
- "type": "timeseries"
+ "editorMode": "code",
+ "expr": "schema_engine{name=~\"schema_file_pinned_num|schema_file_unpinned_num\",instance=~\"$instance\"}",
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Schema File Memory MNode Number",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green"
+ },
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 0,
+ "y": 51
+ },
+ "id": 221,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
},
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
+ "editorMode": "code",
+ "expr": "schema_engine{name=~\"schema_file_flush_thread_num|schema_file_release_thread_num\",instance=~\"$instance\"}",
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Release and Flush Thread Number",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green"
},
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "color": "red",
+ "value": 80
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 12,
- "y": 48
- },
- "id": 229,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
- },
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "schema_engine_seconds{name=~\"schema_file_release|schema_file_flush\",quantile=\"0.5\",instance=~\"$instance\"}",
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Time Consumed of Relead and Flush (99%)",
- "type": "timeseries"
+ ]
+ }
},
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 6,
+ "y": 51
+ },
+ "id": 223,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "palette-classic"
- },
- "custom": {
- "axisCenteredZero": false,
- "axisColorMode": "text",
- "axisLabel": "",
- "axisPlacement": "auto",
- "barAlignment": 0,
- "drawStyle": "line",
- "fillOpacity": 0,
- "gradientMode": "none",
- "hideFrom": {
- "legend": false,
- "tooltip": false,
- "viz": false
- },
- "lineInterpolation": "linear",
- "lineWidth": 1,
- "pointSize": 1,
- "scaleDistribution": {
- "type": "linear"
- },
- "showPoints": "auto",
- "spanNulls": false,
- "stacking": {
- "group": "A",
- "mode": "none"
- },
- "thresholdsStyle": {
- "mode": "off"
- }
+ "editorMode": "code",
+ "expr": "rate(schema_engine_seconds_count{name=~\"schema_file_release|schema_file_flush\",instance=~\"$instance\"}[1m])",
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
+ }
+ ],
+ "title": "Release and Flush MNode Rate",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "description": "",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
},
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green"
- },
- {
- "color": "red",
- "value": 80
- }
- ]
+ {
+ "color": "red",
+ "value": 80
}
- },
- "overrides": []
- },
- "gridPos": {
- "h": 7,
- "w": 6,
- "x": 18,
- "y": 48
- },
- "id": 228,
- "options": {
- "legend": {
- "calcs": [],
- "displayMode": "list",
- "placement": "bottom",
- "showLegend": true
- },
- "tooltip": {
- "mode": "single",
- "sort": "none"
- }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 12,
+ "y": 51
+ },
+ "id": 229,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
+ "targets": [
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
},
- "targets": [
- {
- "datasource": {
- "type": "prometheus",
- "uid": "${DS_PROMETHEUS}"
- },
- "editorMode": "code",
- "expr": "rate(schema_engine_seconds_sum{name=~\"schema_file_release|schema_file_flush\",instance=~\"$instance\"}[1m])/rate(schema_engine_seconds_count{name=~\"schema_file_release|schema_file_flush\",instance=~\"$instance\"}[1m])",
- "legendFormat": "{{name}}",
- "range": true,
- "refId": "A"
- }
- ],
- "title": "Time Consumed of Relead and Flush (avg)",
- "type": "timeseries"
+ "editorMode": "code",
+ "expr": "schema_engine_seconds{name=~\"schema_file_release|schema_file_flush\",quantile=\"0.5\",instance=~\"$instance\"}",
+ "legendFormat": "{{name}}",
+ "range": true,
+ "refId": "A"
}
],
+ "title": "Time Consumed of Relead and Flush (99%)",
+ "type": "timeseries"
+ },
+ {
+ "datasource": {
+ "type": "prometheus",
+ "uid": "${DS_PROMETHEUS}"
+ },
+ "description": "",
+ "fieldConfig": {
+ "defaults": {
+ "color": {
+ "mode": "palette-classic"
+ },
+ "custom": {
+ "axisCenteredZero": false,
+ "axisColorMode": "text",
+ "axisLabel": "",
+ "axisPlacement": "auto",
+ "barAlignment": 0,
+ "drawStyle": "line",
+ "fillOpacity": 0,
+ "gradientMode": "none",
+ "hideFrom": {
+ "legend": false,
+ "tooltip": false,
+ "viz": false
+ },
+ "lineInterpolation": "linear",
+ "lineWidth": 1,
+ "pointSize": 1,
+ "scaleDistribution": {
+ "type": "linear"
+ },
+ "showPoints": "auto",
+ "spanNulls": false,
+ "stacking": {
+ "group": "A",
+ "mode": "none"
+ },
+ "thresholdsStyle": {
+ "mode": "off"
+ }
+ },
+ "mappings": [],
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ {
+ "color": "green",
+ "value": null
+ },
+ {
+ "color": "red",
+ "value": 80
+ }
+ ]
+ }
+ },
+ "overrides": []
+ },
+ "gridPos": {
+ "h": 7,
+ "w": 6,
+ "x": 18,
+ "y": 51
+ },
+ "id": 228,
+ "options": {
+ "legend": {
+ "calcs": [],
+ "displayMode": "list",
+ "placement": "bottom",
+ "showLegend": true
+ },
+ "tooltip": {
+ "mode": "single",
+ "sort": "none"
+ }
+ },
"targets": [
{
"datasource": {
"type": "prometheus",
- "uid": "Ar7cRMx4z"
+ "uid": "${DS_PROMETHEUS}"
},
+ "editorMode": "code",
+ "expr": "rate(schema_engine_seconds_sum{name=~\"schema_file_release|schema_file_flush\",instance=~\"$instance\"}[1m])/rate(schema_engine_seconds_count{name=~\"schema_file_release|schema_file_flush\",instance=~\"$instance\"}[1m])",
+ "legendFormat": "{{name}}",
+ "range": true,
"refId": "A"
}
],
- "title": "Schema Engine",
- "type": "row"
+ "title": "Time Consumed of Relead and Flush (avg)",
+ "type": "timeseries"
},
{
"collapsed": true,
@@ -17269,7 +17626,7 @@
"h": 1,
"w": 24,
"x": 0,
- "y": 11
+ "y": 58
},
"id": 231,
"panels": [
@@ -17318,7 +17675,8 @@
"mode": "absolute",
"steps": [
{
- "color": "green"
+ "color": "green",
+ "value": null
},
{
"color": "red",
@@ -17334,7 +17692,7 @@
"h": 9,
"w": 8,
"x": 0,
- "y": 11
+ "y": 76
},
"id": 237,
"options": {
@@ -17410,7 +17768,8 @@
"mode": "absolute",
"steps": [
{
- "color": "green"
+ "color": "green",
+ "value": null
},
{
"color": "red",
@@ -17425,7 +17784,7 @@
"h": 9,
"w": 9,
"x": 8,
- "y": 11
+ "y": 76
},
"id": 235,
"options": {
@@ -17471,7 +17830,8 @@
"mode": "absolute",
"steps": [
{
- "color": "green"
+ "color": "green",
+ "value": null
},
{
"color": "red",
@@ -17487,7 +17847,7 @@
"h": 9,
"w": 7,
"x": 17,
- "y": 11
+ "y": 76
},
"id": 239,
"options": {
@@ -17504,7 +17864,7 @@
},
"textMode": "auto"
},
- "pluginVersion": "9.3.6",
+ "pluginVersion": "9.3.1",
"targets": [
{
"datasource": {
@@ -17582,7 +17942,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 20
+ "y": 85
},
"id": 271,
"options": {
@@ -17674,7 +18034,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 20
+ "y": 85
},
"id": 272,
"options": {
@@ -17765,7 +18125,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 28
+ "y": 93
},
"id": 274,
"options": {
@@ -17856,7 +18216,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 28
+ "y": 93
},
"id": 275,
"options": {
@@ -17948,7 +18308,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 36
+ "y": 101
},
"id": 277,
"options": {
@@ -18041,7 +18401,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 36
+ "y": 101
},
"id": 279,
"options": {
@@ -18133,7 +18493,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 44
+ "y": 109
},
"id": 265,
"options": {
@@ -18224,7 +18584,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 44
+ "y": 109
},
"id": 267,
"options": {
@@ -18316,7 +18676,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 52
+ "y": 117
},
"id": 269,
"options": {
@@ -18426,7 +18786,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 52
+ "y": 117
},
"id": 253,
"options": {
@@ -18522,7 +18882,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 60
+ "y": 125
},
"id": 281,
"options": {
@@ -18626,7 +18986,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 60
+ "y": 125
},
"id": 247,
"options": {
@@ -18718,7 +19078,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 68
+ "y": 133
},
"id": 251,
"options": {
@@ -18810,7 +19170,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 68
+ "y": 133
},
"id": 263,
"options": {
@@ -18902,7 +19262,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 76
+ "y": 141
},
"id": 245,
"options": {
@@ -18994,7 +19354,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 76
+ "y": 141
},
"id": 241,
"options": {
@@ -19086,7 +19446,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 84
+ "y": 149
},
"id": 249,
"options": {
@@ -19178,7 +19538,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 84
+ "y": 149
},
"id": 243,
"options": {
@@ -19270,7 +19630,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 92
+ "y": 157
},
"id": 262,
"options": {
@@ -19362,7 +19722,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 92
+ "y": 157
},
"id": 257,
"options": {
@@ -19479,7 +19839,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 100
+ "y": 165
},
"id": 261,
"options": {
@@ -19572,7 +19932,7 @@
"h": 8,
"w": 12,
"x": 12,
- "y": 100
+ "y": 165
},
"id": 255,
"options": {
@@ -19664,7 +20024,7 @@
"h": 8,
"w": 12,
"x": 0,
- "y": 108
+ "y": 173
},
"id": 259,
"options": {
diff --git a/docs/UserGuide/Monitor-Alert/Metric-Tool.md b/docs/UserGuide/Monitor-Alert/Metric-Tool.md
index 1ffaa3799e..5f682aa7ee 100644
--- a/docs/UserGuide/Monitor-Alert/Metric-Tool.md
+++ b/docs/UserGuide/Monitor-Alert/Metric-Tool.md
@@ -439,15 +439,19 @@ carefully evaluated. The current Core-level metrics are as follows:
#### 4.2.16 Schema Engine
-| Metric | Tags | Type | Description |
-| ------------- | ------------------------------------------------------------------ | --------- | -------------------------------------- |
-| schema_engine | name="schema_region_total_mem_usage" | AutoGauge | Memory usgae for all SchemaRegion |
-| schema_engine | name="schema_region_mem_capacity" | AutoGauge | Memory capacity for all SchemaRegion |
-| schema_engine | name="schema_engine_mode" | Gauge | Mode of SchemaEngine |
-| schema_engine | name="schema_region_consensus" | Gauge | Consensus protocol of SchemaRegion |
-| schema_engine | name="schema_region_number" | AutoGauge | Number of SchemaRegion |
-| schema_region | name="schema_region_mem_usage", region="SchemaRegion[{regionId}]" | AutoGauge | Memory usgae for each SchemaRegion |
-| schema_region | name="schema_region_series_cnt", region="SchemaRegion[{regionId}]" | AutoGauge | Timeseries count for each SchemaRegion |
+| Metric | Tags | Type | Description |
+| ------------- | ------------------------------------------------------------ | --------- | -------------------------------------------------- |
+| schema_engine | name="schema_region_total_mem_usage" | AutoGauge | Memory usgae for all SchemaRegion |
+| schema_engine | name="schema_region_mem_capacity" | AutoGauge | Memory capacity for all SchemaRegion |
+| schema_engine | name="schema_engine_mode" | Gauge | Mode of SchemaEngine |
+| schema_engine | name="schema_region_consensus" | Gauge | Consensus protocol of SchemaRegion |
+| schema_engine | name="schema_region_number" | AutoGauge | Number of SchemaRegion |
+| quantity | name="template_series_cnt" | AutoGauge | Number of template series |
+| schema_region | name="schema_region_mem_usage", region="SchemaRegion[{regionId}]" | AutoGauge | Memory usgae for each SchemaRegion |
+| schema_region | name="schema_region_series_cnt", region="SchemaRegion[{regionId}]" | AutoGauge | Number of total timeseries for each SchemaRegion |
+| schema_region | name="activated_template_cnt", region="SchemaRegion[{regionId}]" | AutoGauge | Number of Activated template for each SchemaRegion |
+| schema_region | name="template_series_cnt", region="SchemaRegion[{regionId}]" | AutoGauge | Number of template series for each SchemaRegion |
+
#### 4.2.17 Write Performance
| Metric | Tags | Type | Description |
diff --git a/docs/zh/UserGuide/Monitor-Alert/Metric-Tool.md b/docs/zh/UserGuide/Monitor-Alert/Metric-Tool.md
index 22bf19ddec..f168782ceb 100644
--- a/docs/zh/UserGuide/Monitor-Alert/Metric-Tool.md
+++ b/docs/zh/UserGuide/Monitor-Alert/Metric-Tool.md
@@ -419,15 +419,18 @@ Core 级别的监控指标在系统运行中默认开启,每一个 Core 级别
#### 4.2.16 元数据引擎统计
-| Metric | Tags | Type | Description |
-| ------------- | ------------------------------------------------------------------ | --------- | ---------------------------------- |
-| schema_engine | name="schema_region_total_mem_usage" | AutoGauge | SchemaRegion 全局内存使用量 |
-| schema_engine | name="schema_region_mem_capacity" | AutoGauge | SchemaRegion 全局可用内存 |
-| schema_engine | name="schema_engine_mode" | Gauge | SchemaEngine 模式 |
-| schema_engine | name="schema_region_consensus" | Gauge | 元数据管理引擎共识协议 |
-| schema_engine | name="schema_region_number" | AutoGauge | SchemaRegion 个数 |
-| schema_region | name="schema_region_mem_usage", region="SchemaRegion[{regionId}]" | AutoGauge | 每个 SchemaRegion 分别的内存使用量 |
+| Metric | Tags | Type | Description |
+| ------------- | ------------------------------------------------------------ | --------- | ---------------------------------- |
+| schema_engine | name="schema_region_total_mem_usage" | AutoGauge | SchemaRegion 全局内存使用量 |
+| schema_engine | name="schema_region_mem_capacity" | AutoGauge | SchemaRegion 全局可用内存 |
+| schema_engine | name="schema_engine_mode" | Gauge | SchemaEngine 模式 |
+| schema_engine | name="schema_region_consensus" | Gauge | 元数据管理引擎共识协议 |
+| schema_engine | name="schema_region_number" | AutoGauge | SchemaRegion 个数 |
+| quantity | name="template_series_cnt" | AutoGauge | 模板序列数 |
+| schema_region | name="schema_region_mem_usage", region="SchemaRegion[{regionId}]" | AutoGauge | 每个 SchemaRegion 分别的内存使用量 |
| schema_region | name="schema_region_series_cnt", region="SchemaRegion[{regionId}]" | AutoGauge | 每个 SchemaRegion 分别的时间序列数 |
+| schema_region | name="activated_template_cnt", region="SchemaRegion[{regionId}]" | AutoGauge | 每个 SchemaRegion 激活的模板数 |
+| schema_region | name="template_series_cnt", region="SchemaRegion[{regionId}]" | AutoGauge | 每个 SchemaRegion 的模板序列数 |
#### 4.2.17 写入指标统计
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaEngineMemMetric.java b/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaEngineMemMetric.java
index 8d56139e63..54f282fbb2 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaEngineMemMetric.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaEngineMemMetric.java
@@ -39,6 +39,8 @@ public class SchemaEngineMemMetric implements ISchemaEngineMetric {
private static final String SCHEMA_CONSENSUS = "schema_region_consensus";
private static final String SCHEMA_ENGINE_MODE = "schema_engine_mode";
+ private static final String TEMPLATE_SERIES_CNT = "template_series_cnt";
+
private final MemSchemaEngineStatistics engineStatistics;
public SchemaEngineMemMetric(MemSchemaEngineStatistics engineStatistics) {
@@ -54,6 +56,13 @@ public class SchemaEngineMemMetric implements ISchemaEngineMetric {
ISchemaEngineStatistics::getTotalSeriesNumber,
Tag.NAME.toString(),
TIME_SERES_CNT);
+ metricService.createAutoGauge(
+ Metric.QUANTITY.toString(),
+ MetricLevel.IMPORTANT,
+ engineStatistics,
+ ISchemaEngineStatistics::getTemplateSeriesNumber,
+ Tag.NAME.toString(),
+ TEMPLATE_SERIES_CNT);
metricService.createAutoGauge(
Metric.MEM.toString(),
MetricLevel.IMPORTANT,
@@ -100,7 +109,12 @@ public class SchemaEngineMemMetric implements ISchemaEngineMetric {
@Override
public void unbindFrom(AbstractMetricService metricService) {
metricService.remove(
- MetricType.AUTO_GAUGE, Metric.QUANTITY.toString(), Tag.NAME.toString(), "timeSeries");
+ MetricType.AUTO_GAUGE, Metric.QUANTITY.toString(), Tag.NAME.toString(), TIME_SERES_CNT);
+ metricService.remove(
+ MetricType.AUTO_GAUGE,
+ Metric.QUANTITY.toString(),
+ Tag.NAME.toString(),
+ TEMPLATE_SERIES_CNT);
metricService.remove(
MetricType.AUTO_GAUGE,
Metric.MEM.toString(),
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaRegionMemMetric.java b/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaRegionMemMetric.java
index a7475537d4..1fc4f4dd63 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaRegionMemMetric.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/metric/SchemaRegionMemMetric.java
@@ -29,6 +29,8 @@ public class SchemaRegionMemMetric implements ISchemaRegionMetric {
private static final String MEM_USAGE = "schema_region_mem_usage";
private static final String SERIES_CNT = "schema_region_series_cnt";
+ private static final String TEMPLATE_CNT = "activated_template_cnt";
+ private static final String TEMPLATE_SERIES_CNT = "template_series_cnt";
private final MemSchemaRegionStatistics regionStatistics;
private final String regionTagValue;
@@ -58,6 +60,24 @@ public class SchemaRegionMemMetric implements ISchemaRegionMetric {
SERIES_CNT,
Tag.REGION.toString(),
regionTagValue);
+ metricService.createAutoGauge(
+ Metric.SCHEMA_REGION.toString(),
+ MetricLevel.IMPORTANT,
+ regionStatistics,
+ MemSchemaRegionStatistics::getTemplateActivatedNumber,
+ Tag.NAME.toString(),
+ TEMPLATE_CNT,
+ Tag.REGION.toString(),
+ regionTagValue);
+ metricService.createAutoGauge(
+ Metric.SCHEMA_REGION.toString(),
+ MetricLevel.IMPORTANT,
+ regionStatistics,
+ MemSchemaRegionStatistics::getTemplateSeriesNumber,
+ Tag.NAME.toString(),
+ TEMPLATE_SERIES_CNT,
+ Tag.REGION.toString(),
+ regionTagValue);
}
@Override
@@ -76,5 +96,19 @@ public class SchemaRegionMemMetric implements ISchemaRegionMetric {
SERIES_CNT,
Tag.REGION.toString(),
regionTagValue);
+ metricService.remove(
+ MetricType.AUTO_GAUGE,
+ Metric.SCHEMA_REGION.toString(),
+ Tag.NAME.toString(),
+ TEMPLATE_CNT,
+ Tag.REGION.toString(),
+ regionTagValue);
+ metricService.remove(
+ MetricType.AUTO_GAUGE,
+ Metric.SCHEMA_REGION.toString(),
+ Tag.NAME.toString(),
+ TEMPLATE_SERIES_CNT,
+ Tag.REGION.toString(),
+ regionTagValue);
}
}
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGCachedImpl.java b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGCachedImpl.java
index e754bbf616..3df1436432 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGCachedImpl.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGCachedImpl.java
@@ -109,6 +109,7 @@ public class MTreeBelowSGCachedImpl {
private final Function<IMeasurementMNode<ICachedMNode>, Map<String, String>> tagGetter;
private final IMNodeFactory<ICachedMNode> nodeFactory = CacheMNodeFactory.getInstance();
private final int levelOfSG;
+ private final CachedSchemaRegionStatistics regionStatistics;
// region MTree initialization, clear and serialization
public MTreeBelowSGCachedImpl(
@@ -120,6 +121,7 @@ public class MTreeBelowSGCachedImpl {
CachedSchemaRegionStatistics regionStatistics)
throws MetadataException, IOException {
this.tagGetter = tagGetter;
+ this.regionStatistics = regionStatistics;
store = new CachedMTreeStore(storageGroupPath, schemaRegionId, regionStatistics, flushCallback);
this.storageGroupMNode = store.getRoot();
this.storageGroupMNode.setParent(storageGroupMNode.getParent());
@@ -146,21 +148,28 @@ public class MTreeBelowSGCachedImpl {
PartialPath storageGroupPath,
CachedMTreeStore store,
Consumer<IMeasurementMNode<ICachedMNode>> measurementProcess,
- Function<IMeasurementMNode<ICachedMNode>, Map<String, String>> tagGetter)
+ Consumer<IDeviceMNode<ICachedMNode>> deviceProcess,
+ Function<IMeasurementMNode<ICachedMNode>, Map<String, String>> tagGetter,
+ CachedSchemaRegionStatistics regionStatistics)
throws MetadataException {
this.store = store;
+ this.regionStatistics = regionStatistics;
this.storageGroupMNode = store.getRoot();
this.rootNode = store.generatePrefix(storageGroupPath);
levelOfSG = storageGroupMNode.getPartialPath().getNodeLength() - 1;
this.tagGetter = tagGetter;
// recover measurement
- try (MeasurementCollector<Void, ICachedMNode> collector =
- new MeasurementCollector<Void, ICachedMNode>(
+ try (MNodeCollector<Void, ICachedMNode> collector =
+ new MNodeCollector<Void, ICachedMNode>(
this.rootNode, new PartialPath(storageGroupMNode.getFullPath()), this.store, true) {
-
- protected Void collectMeasurement(IMeasurementMNode<ICachedMNode> node) {
- measurementProcess.accept(node);
+ @Override
+ protected Void collectMNode(ICachedMNode node) {
+ if (node.isMeasurement()) {
+ measurementProcess.accept(node.getAsMeasurementMNode());
+ } else if (node.isDevice()) {
+ deviceProcess.accept(node.getAsDeviceMNode());
+ }
return null;
}
}) {
@@ -190,6 +199,7 @@ public class MTreeBelowSGCachedImpl {
int schemaRegionId,
CachedSchemaRegionStatistics regionStatistics,
Consumer<IMeasurementMNode<ICachedMNode>> measurementProcess,
+ Consumer<IDeviceMNode<ICachedMNode>> deviceProcess,
Function<IMeasurementMNode<ICachedMNode>, Map<String, String>> tagGetter,
Runnable flushCallback)
throws IOException, MetadataException {
@@ -198,7 +208,9 @@ public class MTreeBelowSGCachedImpl {
CachedMTreeStore.loadFromSnapshot(
snapshotDir, storageGroupFullPath, schemaRegionId, regionStatistics, flushCallback),
measurementProcess,
- tagGetter);
+ deviceProcess,
+ tagGetter,
+ regionStatistics);
}
// endregion
@@ -832,6 +844,7 @@ public class MTreeBelowSGCachedImpl {
entityMNode.setSchemaTemplateId(template.getId());
store.updateMNode(entityMNode.getAsMNode());
+ regionStatistics.activateTemplate(template.getId());
} finally {
unPinPath(cur);
}
@@ -894,6 +907,7 @@ public class MTreeBelowSGCachedImpl {
&& node.isPreDeactivateTemplate()) {
resultTemplateSetInfo.put(
node.getPartialPath(), Collections.singletonList(node.getSchemaTemplateId()));
+ regionStatistics.deactivateTemplate(node.getSchemaTemplateId());
node.deactivateTemplate();
store.updateMNode(node.getAsMNode());
}
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGMemoryImpl.java b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGMemoryImpl.java
index 7e3c558b1c..9d03f3075e 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGMemoryImpl.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/MTreeBelowSGMemoryImpl.java
@@ -110,6 +110,7 @@ public class MTreeBelowSGMemoryImpl {
private final Function<IMeasurementMNode<IMemMNode>, Map<String, String>> tagGetter;
private final IMNodeFactory<IMemMNode> nodeFactory = MemMNodeFactory.getInstance();
private final int levelOfSG;
+ private final MemSchemaRegionStatistics regionStatistics;
// region MTree initialization, clear and serialization
public MTreeBelowSGMemoryImpl(
@@ -117,6 +118,7 @@ public class MTreeBelowSGMemoryImpl {
Function<IMeasurementMNode<IMemMNode>, Map<String, String>> tagGetter,
MemSchemaRegionStatistics regionStatistics) {
store = new MemMTreeStore(storageGroupPath, regionStatistics);
+ this.regionStatistics = regionStatistics;
this.storageGroupMNode = store.getRoot();
this.rootNode = store.generatePrefix(storageGroupPath);
levelOfSG = storageGroupPath.getNodeLength() - 1;
@@ -126,8 +128,10 @@ public class MTreeBelowSGMemoryImpl {
private MTreeBelowSGMemoryImpl(
PartialPath storageGroupPath,
MemMTreeStore store,
- Function<IMeasurementMNode<IMemMNode>, Map<String, String>> tagGetter) {
+ Function<IMeasurementMNode<IMemMNode>, Map<String, String>> tagGetter,
+ MemSchemaRegionStatistics regionStatistics) {
this.store = store;
+ this.regionStatistics = regionStatistics;
this.storageGroupMNode = store.getRoot();
this.rootNode = store.generatePrefix(storageGroupPath);
levelOfSG = storageGroupPath.getNodeLength() - 1;
@@ -155,12 +159,15 @@ public class MTreeBelowSGMemoryImpl {
String storageGroupFullPath,
MemSchemaRegionStatistics regionStatistics,
Consumer<IMeasurementMNode<IMemMNode>> measurementProcess,
+ Consumer<IDeviceMNode<IMemMNode>> deviceProcess,
Function<IMeasurementMNode<IMemMNode>, Map<String, String>> tagGetter)
throws IOException, IllegalPathException {
return new MTreeBelowSGMemoryImpl(
new PartialPath(storageGroupFullPath),
- MemMTreeStore.loadFromSnapshot(snapshotDir, measurementProcess, regionStatistics),
- tagGetter);
+ MemMTreeStore.loadFromSnapshot(
+ snapshotDir, measurementProcess, deviceProcess, regionStatistics),
+ tagGetter,
+ regionStatistics);
}
// endregion
@@ -710,6 +717,7 @@ public class MTreeBelowSGMemoryImpl {
}
entityMNode.setUseTemplate(true);
entityMNode.setSchemaTemplateId(template.getId());
+ regionStatistics.activateTemplate(template.getId());
}
public Map<PartialPath, List<Integer>> constructSchemaBlackListWithTemplate(
@@ -767,6 +775,7 @@ public class MTreeBelowSGMemoryImpl {
&& node.isPreDeactivateTemplate()) {
resultTemplateSetInfo.put(
node.getPartialPath(), Collections.singletonList(node.getSchemaTemplateId()));
+ regionStatistics.deactivateTemplate(node.getSchemaTemplateId());
node.deactivateTemplate();
deleteEmptyInternalMNode(node);
}
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/snapshot/MemMTreeSnapshotUtil.java b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/snapshot/MemMTreeSnapshotUtil.java
index 4b7c29b63d..7da7632185 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/snapshot/MemMTreeSnapshotUtil.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/snapshot/MemMTreeSnapshotUtil.java
@@ -108,12 +108,13 @@ public class MemMTreeSnapshotUtil {
public static IMemMNode loadSnapshot(
File snapshotDir,
Consumer<IMeasurementMNode<IMemMNode>> measurementProcess,
+ Consumer<IDeviceMNode<IMemMNode>> deviceProcess,
MemSchemaRegionStatistics regionStatistics)
throws IOException {
File snapshot =
SystemFileFactory.INSTANCE.getFile(snapshotDir, MetadataConstant.MTREE_SNAPSHOT);
try (BufferedInputStream inputStream = new BufferedInputStream(new FileInputStream(snapshot))) {
- return deserializeFrom(inputStream, measurementProcess, regionStatistics);
+ return deserializeFrom(inputStream, measurementProcess, deviceProcess, regionStatistics);
} catch (Throwable e) {
// This method is only invoked during recovery. If failed, the memory usage should be cleared
// since the loaded schema will not be used.
@@ -158,15 +159,17 @@ public class MemMTreeSnapshotUtil {
private static IMemMNode deserializeFrom(
InputStream inputStream,
Consumer<IMeasurementMNode<IMemMNode>> measurementProcess,
+ Consumer<IDeviceMNode<IMemMNode>> deviceProcess,
MemSchemaRegionStatistics regionStatistics)
throws IOException {
byte version = ReadWriteIOUtils.readByte(inputStream);
- return inorderDeserialize(inputStream, measurementProcess, regionStatistics);
+ return inorderDeserialize(inputStream, measurementProcess, deviceProcess, regionStatistics);
}
private static IMemMNode inorderDeserialize(
InputStream inputStream,
Consumer<IMeasurementMNode<IMemMNode>> measurementProcess,
+ Consumer<IDeviceMNode<IMemMNode>> deviceProcess,
MemSchemaRegionStatistics regionStatistics)
throws IOException {
MNodeDeserializer deserializer = new MNodeDeserializer();
@@ -178,6 +181,7 @@ public class MemMTreeSnapshotUtil {
deserializer,
inputStream,
measurementProcess,
+ deviceProcess,
regionStatistics);
int childrenNum;
IMemMNode root = ancestors.peek();
@@ -193,6 +197,7 @@ public class MemMTreeSnapshotUtil {
deserializer,
inputStream,
measurementProcess,
+ deviceProcess,
regionStatistics);
}
}
@@ -205,6 +210,7 @@ public class MemMTreeSnapshotUtil {
MNodeDeserializer deserializer,
InputStream inputStream,
Consumer<IMeasurementMNode<IMemMNode>> measurementProcess,
+ Consumer<IDeviceMNode<IMemMNode>> deviceProcess,
MemSchemaRegionStatistics regionStatistics)
throws IOException {
byte type = ReadWriteIOUtils.readByte(inputStream);
@@ -222,10 +228,12 @@ public class MemMTreeSnapshotUtil {
case ENTITY_MNODE_TYPE:
childrenNum = ReadWriteIOUtils.readInt(inputStream);
node = deserializer.deserializeEntityMNode(inputStream);
+ deviceProcess.accept(node.getAsDeviceMNode());
break;
case STORAGE_GROUP_ENTITY_MNODE_TYPE:
childrenNum = ReadWriteIOUtils.readInt(inputStream);
node = deserializer.deserializeStorageGroupEntityMNode(inputStream);
+ deviceProcess.accept(node.getAsDeviceMNode());
break;
case MEASUREMENT_MNODE_TYPE:
childrenNum = 0;
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/store/MemMTreeStore.java b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/store/MemMTreeStore.java
index 70d8269bd4..356a15d3c6 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/mtree/store/MemMTreeStore.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/mtree/store/MemMTreeStore.java
@@ -210,10 +210,12 @@ public class MemMTreeStore implements IMTreeStore<IMemMNode> {
public static MemMTreeStore loadFromSnapshot(
File snapshotDir,
Consumer<IMeasurementMNode<IMemMNode>> measurementProcess,
+ Consumer<IDeviceMNode<IMemMNode>> deviceProcess,
MemSchemaRegionStatistics regionStatistics)
throws IOException {
return new MemMTreeStore(
- MemMTreeSnapshotUtil.loadSnapshot(snapshotDir, measurementProcess, regionStatistics),
+ MemMTreeSnapshotUtil.loadSnapshot(
+ snapshotDir, measurementProcess, deviceProcess, regionStatistics),
regionStatistics);
}
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaEngineStatistics.java b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaEngineStatistics.java
index 5109c7a083..88189f68b1 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaEngineStatistics.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaEngineStatistics.java
@@ -32,6 +32,8 @@ public interface ISchemaEngineStatistics {
int getSchemaRegionNumber();
+ long getTemplateSeriesNumber();
+
MemSchemaEngineStatistics getAsMemSchemaEngineStatistics();
CachedSchemaEngineStatistics getAsCachedSchemaEngineStatistics();
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaRegionStatistics.java b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaRegionStatistics.java
index a03d229b70..6dade84995 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaRegionStatistics.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/ISchemaRegionStatistics.java
@@ -28,6 +28,10 @@ public interface ISchemaRegionStatistics {
long getSeriesNumber();
+ int getTemplateActivatedNumber();
+
+ long getTemplateSeriesNumber();
+
MemSchemaRegionStatistics getAsMemSchemaRegionStatistics();
CachedSchemaRegionStatistics getAsCachedSchemaRegionStatistics();
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaEngineStatistics.java b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaEngineStatistics.java
index 7fad2d55e5..a683e343dc 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaEngineStatistics.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaEngineStatistics.java
@@ -20,10 +20,13 @@ package org.apache.iotdb.db.metadata.rescon;
import org.apache.iotdb.db.conf.IoTDBDescriptor;
import org.apache.iotdb.db.metadata.schemaregion.SchemaEngine;
+import org.apache.iotdb.db.metadata.template.ClusterTemplateManager;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.atomic.AtomicLong;
/** This class is used to record the global statistics of SchemaEngine in Memory mode */
@@ -39,6 +42,8 @@ public class MemSchemaEngineStatistics implements ISchemaEngineStatistics {
private final AtomicLong totalSeriesNumber = new AtomicLong(0);
+ private final Map<Integer, Integer> templateUsage = new ConcurrentHashMap<>();
+
private volatile boolean allowToCreateNewSeries = true;
@Override
@@ -82,7 +87,7 @@ public class MemSchemaEngineStatistics implements ISchemaEngineStatistics {
@Override
public long getTotalSeriesNumber() {
- return totalSeriesNumber.get();
+ return totalSeriesNumber.get() + getTemplateSeriesNumber();
}
@Override
@@ -90,6 +95,25 @@ public class MemSchemaEngineStatistics implements ISchemaEngineStatistics {
return SchemaEngine.getInstance().getSchemaRegionNumber();
}
+ @Override
+ public long getTemplateSeriesNumber() {
+ ClusterTemplateManager clusterTemplateManager = ClusterTemplateManager.getInstance();
+ return templateUsage.entrySet().stream()
+ .mapToLong(
+ i ->
+ (long) clusterTemplateManager.getTemplate(i.getKey()).getMeasurementNumber()
+ * i.getValue())
+ .sum();
+ }
+
+ public void activateTemplate(int templateId) {
+ templateUsage.compute(templateId, (k, v) -> (v == null) ? 1 : v + 1);
+ }
+
+ public void deactivateTemplate(int templateId, int cnt) {
+ templateUsage.compute(templateId, (k, v) -> (v == null || v <= cnt) ? null : v - cnt);
+ }
+
public void addTimeseries(long addedNum) {
totalSeriesNumber.addAndGet(addedNum);
}
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaRegionStatistics.java b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaRegionStatistics.java
index 96f1895334..c8747d3b07 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaRegionStatistics.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/rescon/MemSchemaRegionStatistics.java
@@ -18,6 +18,10 @@
*/
package org.apache.iotdb.db.metadata.rescon;
+import org.apache.iotdb.db.metadata.template.ClusterTemplateManager;
+
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.atomic.AtomicLong;
/** This class is used to record statistics within the SchemaRegion in Memory mode */
@@ -27,6 +31,7 @@ public class MemSchemaRegionStatistics implements ISchemaRegionStatistics {
private final int schemaRegionId;
private final AtomicLong memoryUsage = new AtomicLong(0);
private final AtomicLong seriesNumber = new AtomicLong(0);
+ private final Map<Integer, Integer> templateUsage = new ConcurrentHashMap<>();
private long mLogLength = 0;
@@ -52,7 +57,7 @@ public class MemSchemaRegionStatistics implements ISchemaRegionStatistics {
@Override
public long getSeriesNumber() {
- return seriesNumber.get();
+ return seriesNumber.get() + getTemplateSeriesNumber();
}
public void addTimeseries(long addedNum) {
@@ -65,6 +70,32 @@ public class MemSchemaRegionStatistics implements ISchemaRegionStatistics {
schemaEngineStatistics.deleteTimeseries(deletedNum);
}
+ @Override
+ public int getTemplateActivatedNumber() {
+ return templateUsage.size();
+ }
+
+ @Override
+ public long getTemplateSeriesNumber() {
+ ClusterTemplateManager clusterTemplateManager = ClusterTemplateManager.getInstance();
+ return templateUsage.entrySet().stream()
+ .mapToLong(
+ i ->
+ (long) clusterTemplateManager.getTemplate(i.getKey()).getMeasurementNumber()
+ * i.getValue())
+ .sum();
+ }
+
+ public void activateTemplate(int templateId) {
+ templateUsage.compute(templateId, (k, v) -> (v == null) ? 1 : v + 1);
+ schemaEngineStatistics.activateTemplate(templateId);
+ }
+
+ public void deactivateTemplate(int templateId) {
+ templateUsage.compute(templateId, (k, v) -> (v == null || v == 1) ? null : v - 1);
+ schemaEngineStatistics.deactivateTemplate(templateId, 1);
+ }
+
@Override
public long getRegionMemoryUsage() {
return memoryUsage.get();
@@ -99,5 +130,8 @@ public class MemSchemaRegionStatistics implements ISchemaRegionStatistics {
schemaEngineStatistics.deleteTimeseries(seriesNumber.get());
memoryUsage.getAndSet(0);
seriesNumber.getAndSet(0);
+ templateUsage.forEach(
+ (templateId, cnt) -> schemaEngineStatistics.deactivateTemplate(templateId, cnt));
+ templateUsage.clear();
}
}
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionMemoryImpl.java b/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionMemoryImpl.java
index 5bec389692..209c6bc51d 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionMemoryImpl.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionMemoryImpl.java
@@ -477,6 +477,11 @@ public class SchemaRegionMemoryImpl implements ISchemaRegion {
schemaRegionId);
}
},
+ deviceMNode -> {
+ if (deviceMNode.getSchemaTemplateIdWithState() >= 0) {
+ regionStatistics.activateTemplate(deviceMNode.getSchemaTemplateId());
+ }
+ },
tagManager::readTags);
logger.info(
"MTree snapshot loading of schemaRegion {} costs {}ms.",
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionSchemaFileImpl.java b/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionSchemaFileImpl.java
index 38319a833e..8e16a02eca 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionSchemaFileImpl.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionSchemaFileImpl.java
@@ -517,6 +517,11 @@ public class SchemaRegionSchemaFileImpl implements ISchemaRegion {
schemaRegionId);
}
},
+ deviceMNode -> {
+ if (deviceMNode.getSchemaTemplateIdWithState() >= 0) {
+ regionStatistics.activateTemplate(deviceMNode.getSchemaTemplateId());
+ }
+ },
tagManager::readTags,
this::flushCallback);
logger.info(
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/template/ClusterTemplateManager.java b/server/src/main/java/org/apache/iotdb/db/metadata/template/ClusterTemplateManager.java
index 5e85c84374..79016e3e11 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/template/ClusterTemplateManager.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/template/ClusterTemplateManager.java
@@ -26,6 +26,7 @@ import org.apache.iotdb.commons.consensus.ConfigRegionId;
import org.apache.iotdb.commons.exception.IllegalPathException;
import org.apache.iotdb.commons.exception.IoTDBException;
import org.apache.iotdb.commons.path.PartialPath;
+import org.apache.iotdb.commons.utils.TestOnly;
import org.apache.iotdb.confignode.rpc.thrift.TCreateSchemaTemplateReq;
import org.apache.iotdb.confignode.rpc.thrift.TGetAllTemplatesResp;
import org.apache.iotdb.confignode.rpc.thrift.TGetPathsSetTemplatesResp;
@@ -365,4 +366,10 @@ public class ClusterTemplateManager implements ITemplateManager {
readWriteLock.writeLock().unlock();
}
}
+
+ @TestOnly
+ public void putTemplate(Template template) {
+ templateIdMap.put(template.getId(), template);
+ templateNameMap.put(template.getName(), template.getId());
+ }
}
diff --git a/server/src/main/java/org/apache/iotdb/db/metadata/template/Template.java b/server/src/main/java/org/apache/iotdb/db/metadata/template/Template.java
index 1d6688c0ea..33a655b778 100644
--- a/server/src/main/java/org/apache/iotdb/db/metadata/template/Template.java
+++ b/server/src/main/java/org/apache/iotdb/db/metadata/template/Template.java
@@ -112,6 +112,10 @@ public class Template implements Serializable {
return isDirectAligned;
}
+ public int getMeasurementNumber() {
+ return schemaMap.size();
+ }
+
// region construct template tree
private IMeasurementSchema constructSchema(
diff --git a/server/src/test/java/org/apache/iotdb/db/metadata/schemaRegion/SchemaStatisticsTest.java b/server/src/test/java/org/apache/iotdb/db/metadata/schemaRegion/SchemaStatisticsTest.java
index 4318c13f16..f2c86dc0ca 100644
--- a/server/src/test/java/org/apache/iotdb/db/metadata/schemaRegion/SchemaStatisticsTest.java
+++ b/server/src/test/java/org/apache/iotdb/db/metadata/schemaRegion/SchemaStatisticsTest.java
@@ -25,11 +25,14 @@ import org.apache.iotdb.commons.schema.node.IMNode;
import org.apache.iotdb.commons.schema.node.utils.IMNodeFactory;
import org.apache.iotdb.db.metadata.mnode.mem.factory.MemMNodeFactory;
import org.apache.iotdb.db.metadata.mnode.schemafile.factory.CacheMNodeFactory;
+import org.apache.iotdb.db.metadata.plan.schemaregion.impl.write.SchemaRegionWritePlanFactory;
import org.apache.iotdb.db.metadata.rescon.CachedSchemaEngineStatistics;
import org.apache.iotdb.db.metadata.rescon.CachedSchemaRegionStatistics;
import org.apache.iotdb.db.metadata.rescon.ISchemaEngineStatistics;
import org.apache.iotdb.db.metadata.schemaregion.ISchemaRegion;
import org.apache.iotdb.db.metadata.schemaregion.SchemaEngine;
+import org.apache.iotdb.db.metadata.template.ClusterTemplateManager;
+import org.apache.iotdb.db.metadata.template.Template;
import org.apache.iotdb.tsfile.file.metadata.enums.CompressionType;
import org.apache.iotdb.tsfile.file.metadata.enums.TSDataType;
import org.apache.iotdb.tsfile.file.metadata.enums.TSEncoding;
@@ -39,6 +42,9 @@ import org.junit.Assert;
import org.junit.Test;
import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
public class SchemaStatisticsTest extends AbstractSchemaRegionTest {
@@ -247,4 +253,84 @@ public class SchemaStatisticsTest extends AbstractSchemaRegionTest {
engineStatistics.getUnpinnedMemorySize());
}
}
+
+ @Test
+ public void testTemplateStatistics() throws Exception {
+ ISchemaEngineStatistics engineStatistics =
+ SchemaEngine.getInstance().getSchemaEngineStatistics();
+ ISchemaRegion schemaRegion1 = getSchemaRegion("root.sg1", 0);
+ ISchemaRegion schemaRegion2 = getSchemaRegion("root.sg2", 1);
+ schemaRegion1.createTimeseries(
+ SchemaRegionWritePlanFactory.getCreateTimeSeriesPlan(
+ new PartialPath("root.sg.wf01.wt01.status"),
+ TSDataType.BOOLEAN,
+ TSEncoding.PLAIN,
+ CompressionType.SNAPPY,
+ null,
+ null,
+ null,
+ null),
+ -1);
+ Template template1 =
+ new Template(
+ "t1",
+ Arrays.asList("s1", "s2", "s3"),
+ Arrays.asList(TSDataType.DOUBLE, TSDataType.INT32, TSDataType.BOOLEAN),
+ Arrays.asList(TSEncoding.RLE, TSEncoding.RLE, TSEncoding.RLE),
+ Arrays.asList(CompressionType.SNAPPY, CompressionType.SNAPPY, CompressionType.SNAPPY));
+ template1.setId(1);
+ Template template2 =
+ new Template(
+ "t2",
+ Arrays.asList("temperature", "status"),
+ Arrays.asList(TSDataType.DOUBLE, TSDataType.INT32),
+ Arrays.asList(TSEncoding.RLE, TSEncoding.RLE),
+ Arrays.asList(CompressionType.SNAPPY, CompressionType.SNAPPY));
+ template2.setId(2);
+ ClusterTemplateManager.getInstance().putTemplate(template1);
+ ClusterTemplateManager.getInstance().putTemplate(template2);
+ for (int i = 0; i < 4; i++) {
+ schemaRegion1.activateSchemaTemplate(
+ SchemaRegionWritePlanFactory.getActivateTemplateInClusterPlan(
+ new PartialPath("root.sg1.d" + i), 2, 1),
+ template1);
+ schemaRegion2.activateSchemaTemplate(
+ SchemaRegionWritePlanFactory.getActivateTemplateInClusterPlan(
+ new PartialPath("root.sg2.d" + i), 2, 1),
+ template1);
+ }
+ schemaRegion2.activateSchemaTemplate(
+ SchemaRegionWritePlanFactory.getActivateTemplateInClusterPlan(
+ new PartialPath("root.sg2.wf01.wt02"), 3, 2),
+ template2);
+
+ // check template statistic
+ Assert.assertEquals(26, engineStatistics.getTemplateSeriesNumber());
+ Assert.assertEquals(27, engineStatistics.getTotalSeriesNumber());
+ Assert.assertEquals(13, schemaRegion1.getSchemaRegionStatistics().getSeriesNumber());
+ Assert.assertEquals(12, schemaRegion1.getSchemaRegionStatistics().getTemplateSeriesNumber());
+ Assert.assertEquals(14, schemaRegion2.getSchemaRegionStatistics().getSeriesNumber());
+ Assert.assertEquals(14, schemaRegion2.getSchemaRegionStatistics().getTemplateSeriesNumber());
+
+ // deactivate template
+ // construct schema blacklist with template on root.sg.wf01.wt01 and root.sg.wf02
+ Map<PartialPath, List<Integer>> allDeviceTemplateMap = new HashMap<>();
+ allDeviceTemplateMap.put(new PartialPath("root.**.d0"), Arrays.asList(1, 2));
+ schemaRegion1.constructSchemaBlackListWithTemplate(
+ SchemaRegionWritePlanFactory.getPreDeactivateTemplatePlan(allDeviceTemplateMap));
+ schemaRegion2.constructSchemaBlackListWithTemplate(
+ SchemaRegionWritePlanFactory.getPreDeactivateTemplatePlan(allDeviceTemplateMap));
+ schemaRegion1.deactivateTemplateInBlackList(
+ SchemaRegionWritePlanFactory.getDeactivateTemplatePlan(allDeviceTemplateMap));
+ schemaRegion2.deactivateTemplateInBlackList(
+ SchemaRegionWritePlanFactory.getDeactivateTemplatePlan(allDeviceTemplateMap));
+
+ // check template statistic
+ Assert.assertEquals(20, engineStatistics.getTemplateSeriesNumber());
+ Assert.assertEquals(21, engineStatistics.getTotalSeriesNumber());
+ Assert.assertEquals(10, schemaRegion1.getSchemaRegionStatistics().getSeriesNumber());
+ Assert.assertEquals(9, schemaRegion1.getSchemaRegionStatistics().getTemplateSeriesNumber());
+ Assert.assertEquals(11, schemaRegion2.getSchemaRegionStatistics().getSeriesNumber());
+ Assert.assertEquals(11, schemaRegion2.getSchemaRegionStatistics().getTemplateSeriesNumber());
+ }
}