From 4b626754e5c175b76201377eb20db265a223d45b Mon Sep 17 00:00:00 2001 From: Rob Thijssen Date: Fri, 4 Sep 2026 10:18:40 +0300 Subject: [PATCH] grafana: per-author hashrate history panel Each author's estimated hashrate over time: share of blocks authored in the trailing 6 h times the 6 h average network hashrate, legend by the telemetry node name where attributed, else the abbreviated preimage. Authors under 10 MH/s are left out. Makes pool growth visible as a trend rather than a leaderboard snapshot. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_01CBgs2nSi4H2mdh8kD8vMX5 --- asset/grafana/quantus.json | 130 ++++++++++++++++++++++++++++--------- 1 file changed, 101 insertions(+), 29 deletions(-) diff --git a/asset/grafana/quantus.json b/asset/grafana/quantus.json index 12c6bd0..27be047 100644 --- a/asset/grafana/quantus.json +++ b/asset/grafana/quantus.json @@ -9,7 +9,7 @@ ], "timezone": "browser", "schemaVersion": 39, - "version": 20, + "version": 21, "refresh": "30s", "time": { "from": "now-6h", @@ -2310,6 +2310,78 @@ } } }, + { + "type": "timeseries", + "title": "Hashrate by author (6 h share of blocks \u00d7 network hashrate)", + "datasource": { + "type": "prometheus", + "uid": "prometheus" + }, + "gridPos": { + "h": 9, + "w": 24, + "x": 0, + "y": 72 + }, + "description": "Each author's estimated hashrate over time: its share of the blocks authored in the trailing 6 h times the network hashrate averaged over the same 6 h, in MH/s. Authors below 10 MH/s are left out. The legend uses the telemetry node name where the arena exporter has attributed the preimage, else the abbreviated preimage; an author gets a new line when its label changes. Pools grow by headcount, so a steadily rising line with no step is a pool filling up; a step is hardware arriving or leaving. 6 h of blocks is about 1800, so a 3% author's line carries roughly \u00b115% sampling noise.", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "prometheus" + }, + "editorMode": "code", + "refId": "A", + "expr": "(((increase(quantus_blocks_authored_total[6h]) / scalar(sum(increase(quantus_blocks_authored_total[6h]))) * scalar(avg_over_time(quantus_network_hashrate[6h])) / 1e6) * on (preimage) group_left(display) quantus_author_node_info) or label_replace((increase(quantus_blocks_authored_total[6h]) / scalar(sum(increase(quantus_blocks_authored_total[6h]))) * scalar(avg_over_time(quantus_network_hashrate[6h])) / 1e6) unless on (preimage) quantus_author_node_info, \"display\", \"$1\u2026$2\", \"preimage\", \"^(0x[0-9a-f]{6})[0-9a-f]*([0-9a-f]{4})$\")) > 10", + "legendFormat": "{{display}}", + "range": true + } + ], + "fieldConfig": { + "defaults": { + "unit": "none", + "decimals": 0, + "min": 0, + "custom": { + "lineWidth": 2, + "fillOpacity": 0, + "showPoints": "never", + "spanNulls": 3600000 + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "baba-gorchitsa" + }, + "properties": [ + { + "id": "custom.lineWidth", + "value": 3 + } + ] + } + ] + }, + "options": { + "legend": { + "displayMode": "table", + "placement": "right", + "calcs": [ + "lastNotNull", + "mean", + "max" + ], + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "multi", + "sort": "desc" + } + } + }, { "type": "row", "title": "Rewards", @@ -2318,7 +2390,7 @@ "h": 1, "w": 24, "x": 0, - "y": 72 + "y": 81 }, "panels": [] }, @@ -2333,7 +2405,7 @@ "h": 5, "w": 8, "x": 0, - "y": 73 + "y": 82 }, "targets": [ { @@ -2391,7 +2463,7 @@ "h": 9, "w": 16, "x": 8, - "y": 73 + "y": 82 }, "targets": [ { @@ -2443,7 +2515,7 @@ "h": 5, "w": 8, "x": 0, - "y": 78 + "y": 87 }, "targets": [ { @@ -2492,7 +2564,7 @@ "h": 1, "w": 24, "x": 0, - "y": 84 + "y": 93 }, "panels": [] }, @@ -2507,7 +2579,7 @@ "h": 9, "w": 14, "x": 0, - "y": 85 + "y": 94 }, "targets": [ { @@ -2570,7 +2642,7 @@ "h": 9, "w": 10, "x": 14, - "y": 85 + "y": 94 }, "targets": [ { @@ -2620,7 +2692,7 @@ "h": 4, "w": 8, "x": 0, - "y": 94 + "y": 103 }, "targets": [ { @@ -2677,7 +2749,7 @@ "h": 4, "w": 8, "x": 8, - "y": 94 + "y": 103 }, "targets": [ { @@ -2734,7 +2806,7 @@ "h": 4, "w": 8, "x": 16, - "y": 94 + "y": 103 }, "targets": [ { @@ -2805,7 +2877,7 @@ "h": 1, "w": 24, "x": 0, - "y": 98 + "y": 107 }, "panels": [] }, @@ -2820,7 +2892,7 @@ "h": 9, "w": 14, "x": 0, - "y": 99 + "y": 108 }, "targets": [ { @@ -2928,7 +3000,7 @@ "h": 4, "w": 10, "x": 14, - "y": 99 + "y": 108 }, "targets": [ { @@ -2985,7 +3057,7 @@ "h": 5, "w": 10, "x": 14, - "y": 103 + "y": 112 }, "targets": [ { @@ -3037,7 +3109,7 @@ "h": 4, "w": 8, "x": 0, - "y": 112 + "y": 121 }, "targets": [ { @@ -3083,7 +3155,7 @@ "h": 1, "w": 24, "x": 0, - "y": 116 + "y": 125 }, "panels": [] }, @@ -3099,7 +3171,7 @@ "h": 8, "w": 12, "x": 0, - "y": 117 + "y": 126 }, "fieldConfig": { "defaults": { @@ -3161,7 +3233,7 @@ "h": 8, "w": 12, "x": 12, - "y": 117 + "y": 126 }, "fieldConfig": { "defaults": { @@ -3223,7 +3295,7 @@ "h": 8, "w": 12, "x": 0, - "y": 125 + "y": 134 }, "fieldConfig": { "defaults": { @@ -3287,7 +3359,7 @@ "h": 8, "w": 12, "x": 12, - "y": 125 + "y": 134 }, "fieldConfig": { "defaults": { @@ -3351,7 +3423,7 @@ "h": 8, "w": 12, "x": 0, - "y": 133 + "y": 142 }, "fieldConfig": { "defaults": { @@ -3413,7 +3485,7 @@ "h": 8, "w": 12, "x": 12, - "y": 133 + "y": 142 }, "fieldConfig": { "defaults": { @@ -3477,7 +3549,7 @@ "h": 8, "w": 12, "x": 0, - "y": 141 + "y": 150 }, "fieldConfig": { "defaults": { @@ -3539,7 +3611,7 @@ "h": 8, "w": 12, "x": 12, - "y": 141 + "y": 150 }, "fieldConfig": { "defaults": { @@ -3597,7 +3669,7 @@ "h": 1, "w": 24, "x": 0, - "y": 149 + "y": 158 }, "panels": [] }, @@ -3613,7 +3685,7 @@ "h": 9, "w": 8, "x": 0, - "y": 150 + "y": 159 }, "fieldConfig": { "defaults": { @@ -3675,7 +3747,7 @@ "h": 9, "w": 8, "x": 8, - "y": 150 + "y": 159 }, "fieldConfig": { "defaults": { @@ -3737,7 +3809,7 @@ "h": 9, "w": 8, "x": 16, - "y": 150 + "y": 159 }, "fieldConfig": { "defaults": { -- 2.52.0