From c8f4a857201fa85e6eea9bd6622a3952e613be09 Mon Sep 17 00:00:00 2001 From: Ruihang Xia Date: Thu, 25 Jul 2024 04:05:44 +0800 Subject: [PATCH] chore: update grafana dashboard to reflect recent metric changes (#4417) * chore: update grafana dashboard to reflect recent metric changes Signed-off-by: Ruihang Xia * chore: add a blank line at the end --------- Signed-off-by: Ruihang Xia Co-authored-by: dennis zhuang --- grafana/greptimedb.json | 462 +++++++++++++++++++++++++--------------- 1 file changed, 289 insertions(+), 173 deletions(-) diff --git a/grafana/greptimedb.json b/grafana/greptimedb.json index 418c07c3c8c7..e296c36be2b0 100644 --- a/grafana/greptimedb.json +++ b/grafana/greptimedb.json @@ -622,7 +622,7 @@ "x": 0, "y": 11 }, - "id": 13, + "id": 34, "interval": "1s", "options": { "legend": { @@ -644,13 +644,13 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_frontend_handle_sql_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_promql_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{label_name}}-p95", + "legendFormat": "promql-{{db}}-p95", "range": true, - "refId": "A", + "refId": "PromQL P95", "useBackend": false }, { @@ -660,18 +660,70 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_frontend_handle_sql_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_promql_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "hide": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{label_name}}-p99", + "legendFormat": "promql-{{db}}-p99", "range": true, - "refId": "B", + "refId": "PromQL P99", "useBackend": false + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_sql_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "__auto", + "range": true, + "refId": "SQL P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_sql_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "__auto", + "range": true, + "refId": "SQL P99" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_prometheus_read_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "__auto", + "range": true, + "refId": "PromStore Read P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_prometheus_read_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "__auto", + "range": true, + "refId": "PromStore Read P99" } ], - "title": "gRPC insert elapsed", + "title": "HTTP query elapsed", "type": "timeseries" }, { @@ -739,7 +791,7 @@ "x": 12, "y": 11 }, - "id": 20, + "id": 35, "interval": "1s", "options": { "legend": { @@ -761,13 +813,13 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_prometheus_write_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_influxdb_write_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{label_name}}-p95", + "legendFormat": "influx-{{db}}-p95", "range": true, - "refId": "A", + "refId": "InfluxDB Line Protocol P95", "useBackend": false }, { @@ -777,18 +829,148 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_prometheus_write_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_influxdb_write_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "hide": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{label_name}}-p99", + "legendFormat": "influx-{{db}}-p99", "range": true, - "refId": "B", + "refId": "InfluxDB Line Protocol P99", "useBackend": false + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_prometheus_write_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "promstore-{{db}}-p95", + "range": true, + "refId": "PromStore Write P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_prometheus_write_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "promstore-{{db}}-p99", + "range": true, + "refId": "PromStore Write P99" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_otlp_metrics_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "otlp-metric-{{db}}-p95", + "range": true, + "refId": "OTLP Metric P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_otlp_metrics_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "otlp-metric-{{db}}-p99", + "range": true, + "refId": "OTLP Metric P99" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_otlp_traces_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "otlp-trace-{{db}}-p95", + "range": true, + "refId": "OTLP Trace P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_otlp_traces_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "otlp-trace-{{db}}-p99", + "range": true, + "refId": "OTLP Trace P99" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_logs_transform_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "log-transform-{{db}}-p95", + "range": true, + "refId": "Log Transform P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_logs_transform_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "log-transform-{{db}}-p99", + "range": true, + "refId": "Log Transform P99" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_logs_ingestion_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "log-ingest-{{db}}-p99", + "range": true, + "refId": "Log Ingest P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_logs_ingestion_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "log-ingest-{{db}}-p99", + "range": true, + "refId": "Log Ingest P99" } ], - "title": "PromStore write elapsed", + "title": "HTTP write elapsed", "type": "timeseries" }, { @@ -856,7 +1038,7 @@ "x": 0, "y": 18 }, - "id": 34, + "id": 13, "interval": "1s", "options": { "legend": { @@ -878,11 +1060,11 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_http_promql_instant_query_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.95, sum by(le, db) (rate(greptime_servers_grpc_requests_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "instant-{{label_name}}-p95", + "legendFormat": "{{db}}-p95", "range": true, "refId": "A", "useBackend": false @@ -894,44 +1076,18 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_promql_instant_query_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_grpc_requests_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "hide": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "instant-{{label_name}}-p99", + "legendFormat": "{{db}}-p99", "range": true, "refId": "B", "useBackend": false - }, - { - "datasource": { - "type": "prometheus", - "uid": "${DS_PROMETHEUS-1}" - }, - "editorMode": "code", - "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_promql_range_query_elapsed_bucket[$__rate_interval])))", - "hide": false, - "instant": false, - "legendFormat": "range-{{label_name}}-p95", - "range": true, - "refId": "D" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${DS_PROMETHEUS-1}" - }, - "editorMode": "code", - "expr": "histogram_quantile(0.99, sum by(le, db) (rate(greptime_servers_http_promql_range_query_elapsed_bucket[$__rate_interval])))", - "hide": false, - "instant": false, - "legendFormat": "range-{{label_name}}-p99", - "range": true, - "refId": "C" } ], - "title": "HTTP PromQL elapsed", + "title": "gRPC insert elapsed", "type": "timeseries" }, { @@ -1034,11 +1190,11 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.95, sum by(le, type, group) (rate(greptime_mito_handle_request_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.95, sum by(le, type) (rate(greptime_mito_handle_request_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{group}}-{{type}}-p95", + "legendFormat": "{{type}}-p95", "range": true, "refId": "A", "useBackend": false @@ -1050,12 +1206,12 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.99, sum by(le, type, group) (rate(greptime_mito_handle_request_elapsed_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.99, sum by(le, type) (rate(greptime_mito_handle_request_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "hide": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{group}}-{{type}}-p99", + "legendFormat": "{{type}}-p99", "range": true, "refId": "B", "useBackend": false @@ -1441,7 +1597,7 @@ "overrides": [] }, "gridPos": { - "h": 6, + "h": 7, "w": 12, "x": 0, "y": 40 @@ -1554,7 +1710,7 @@ "overrides": [] }, "gridPos": { - "h": 6, + "h": 7, "w": 12, "x": 12, "y": 40 @@ -1613,7 +1769,7 @@ "h": 1, "w": 24, "x": 0, - "y": 46 + "y": 47 }, "id": 26, "panels": [], @@ -1680,10 +1836,10 @@ "overrides": [] }, "gridPos": { - "h": 6, + "h": 7, "w": 12, "x": 0, - "y": 47 + "y": 48 }, "id": 22, "interval": "1s", @@ -1793,10 +1949,10 @@ "overrides": [] }, "gridPos": { - "h": 6, + "h": 7, "w": 12, "x": 12, - "y": 47 + "y": 48 }, "id": 33, "interval": "1s", @@ -1852,7 +2008,7 @@ "h": 1, "w": 24, "x": 0, - "y": 53 + "y": 55 }, "id": 21, "panels": [], @@ -1923,7 +2079,7 @@ "h": 7, "w": 12, "x": 0, - "y": 54 + "y": 56 }, "id": 18, "interval": "1s", @@ -2024,7 +2180,7 @@ "h": 7, "w": 12, "x": 12, - "y": 54 + "y": 56 }, "id": 2, "options": { @@ -2115,8 +2271,7 @@ "value": 80 } ] - }, - "unit": "none" + } }, "overrides": [] }, @@ -2124,9 +2279,9 @@ "h": 7, "w": 12, "x": 0, - "y": 61 + "y": 63 }, - "id": 17, + "id": 10, "interval": "1s", "options": { "legend": { @@ -2146,19 +2301,29 @@ "type": "prometheus", "uid": "${DS_PROMETHEUS-1}" }, - "disableTextWrap": false, "editorMode": "code", - "expr": "rate(raft_engine_sync_log_duration_seconds_count[2s])", - "fullMetaSearch": false, - "includeNullMetadata": false, + "expr": "histogram_quantile(0.99, sum by(le,logstore,optype) (rate(greptime_logstore_op_elapsed_bucket[$__rate_interval])))", + "hide": false, "instant": false, - "legendFormat": "__auto", + "legendFormat": "{{logstore}}-{{optype}}-p95", "range": true, - "refId": "A", - "useBackend": false + "refId": "Log Store P95" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le,logstore,optype) (rate(greptime_logstore_op_elapsed_bucket[$__rate_interval])))", + "hide": false, + "instant": false, + "legendFormat": "{{logstore}}-{{optype}}-p99", + "range": true, + "refId": "Log Store P99" } ], - "title": "raft engine sync count", + "title": "Log Store op duration seconds", "type": "timeseries" }, { @@ -2217,7 +2382,7 @@ } ] }, - "unit": "bytes" + "unit": "none" }, "overrides": [] }, @@ -2225,7 +2390,7 @@ "h": 7, "w": 12, "x": 12, - "y": 61 + "y": 63 }, "id": 19, "interval": "1s", @@ -2249,99 +2414,32 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "rate(greptime_mito_read_row_groups_total[2s])", + "expr": "histogram_quantile(0.95, sum by(le, type) (rate(greptime_index_apply_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "__auto", + "legendFormat": "apply-{{type}}-p95", "range": true, - "refId": "A", + "refId": "Apply P95", "useBackend": false - } - ], - "title": "index", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${DS_PROMETHEUS-1}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisBorderShow": false, - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "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": 12, - "x": 0, - "y": 68 - }, - "id": 10, - "interval": "1s", - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom", - "showLegend": true + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "disableTextWrap": false, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, type) (rate(greptime_index_apply_elapsed_bucket[$__rate_interval])))", + "fullMetaSearch": false, + "hide": false, + "includeNullMetadata": false, + "instant": false, + "legendFormat": "apply-{{type}}-p95", + "range": true, + "refId": "Apply P99", + "useBackend": false }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ { "datasource": { "type": "prometheus", @@ -2349,13 +2447,14 @@ }, "disableTextWrap": false, "editorMode": "code", - "expr": "histogram_quantile(0.95, sum by(le, group) (rate(raft_engine_write_duration_seconds_bucket[$__rate_interval])))", + "expr": "histogram_quantile(0.95, sum by(le, type) (rate(greptime_index_create_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, + "hide": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{group}}-p95", + "legendFormat": "create-{{type}}-p95", "range": true, - "refId": "A", + "refId": "Create P95", "useBackend": false }, { @@ -2364,19 +2463,19 @@ "uid": "${DS_PROMETHEUS-1}" }, "disableTextWrap": false, - "editorMode": "builder", - "expr": "histogram_quantile(0.99, sum by(le, group) (rate(raft_engine_write_duration_seconds_bucket[$__rate_interval])))", + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le, type) (rate(greptime_index_create_elapsed_bucket[$__rate_interval])))", "fullMetaSearch": false, "hide": false, "includeNullMetadata": false, "instant": false, - "legendFormat": "{{group}}-p99", + "legendFormat": "create-{{type}}-p95", "range": true, - "refId": "B", + "refId": "Create P99", "useBackend": false } ], - "title": "raft engine write duration seconds", + "title": "Index elapsed", "type": "timeseries" }, { @@ -2443,7 +2542,7 @@ "h": 7, "w": 12, "x": 12, - "y": 68 + "y": 70 }, "id": 12, "interval": "1s", @@ -2476,6 +2575,23 @@ "refId": "A", "useBackend": false }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS-1}" + }, + "disableTextWrap": false, + "editorMode": "code", + "expr": "histogram_quantile(0.99, sum by(le) (rate(raft_engine_write_size_bucket[$__rate_interval])))", + "fullMetaSearch": false, + "hide": false, + "includeNullMetadata": false, + "instant": false, + "legendFormat": "req-size-p99", + "range": true, + "refId": "C", + "useBackend": false + }, { "datasource": { "type": "prometheus", @@ -2508,6 +2624,6 @@ "timezone": "", "title": "GreptimeDB", "uid": "e7097237-669b-4f8d-b751-13067afbfb68", - "version": 12, + "version": 14, "weekStart": "" -} \ No newline at end of file +}