{"id":"XE-0090","kind":"bounty","visibility":"public","source":"github","source_repo":"xeprotocol/xe","source_ref":"34","source_url":"https://github.com/xeprotocol/xe/issues/34","reporter_id":10,"title":"Track 2 measurement: finality throughput degrades 3x (5.0 -> 1.5 advances/min, 39 blocks per advance) at ~1 tx/s with 30 wallets","area":"ops-testnet","claimed_tier":"medium","assessed_tier":null,"verdict":null,"duplicate_of":null,"tracked":false,"internal_ref":"","internal_url":null,"status":"closed","closed_reason":"withdrawn","github_state":"closed","disclosed_at":null,"award_xe":null,"award_approved":false,"paid_ref":"","created_at":"2026-10-29T13:57:25.567144+00:00","updated_at":"2026-10-29T14:23:20.127803+00:00","source_created_at":"2026-10-24T15:10:21+00:00","told_at":null,"status_changed_at":"2026-10-29T14:22:11.369739+00:00","url":"https://bounty.xe.network/XE-0090","body":"**Severity (suggested):** Medium — reproducible, measurable degradation of finality throughput under a load a single\noperator can generate with 30 wallets. Not a stall and not a liveness failure (no dropped blocks, no 429s, peers stable).\n\n**XE payout address:** `b68f2b4d8a062d9219590f0c2d7753d783ec9f5d43d85a125230bb0f7a41a86e`\n**Campaign notice:** #32\n\n### Setup (as announced in #32, nothing exceeded)\n\n- 30 campaign-controlled wallets, 8 worker threads, 10 minutes, `testnet-0005`, protocol API only\n- ordinary zero-fee `send` blocks, **1 micro-XE** each, well-formed and signed (no malformed input)\n- target 3 tx/s, **achieved 0.94 tx/s** (client is proof-of-work bound; PoW p50 1.43 s per block in our client)\n- 581 submits → **574 confirmed (98.8 %)**, 7 client-side failures (source wallet ran out of 1-micro balance)\n- **0** rate-limit (429) responses, **0** dropped blocks, peer count 5–6 throughout\n\n### What the network did\n\n| metric | idle baseline (2 min, no load) | during the 10-min load |\n|---|---|---|\n| blocks produced | 25 (7.7 / min, ≈0.13 / s) | **+624 (≈1.0 / s, 4.5× the idle block rate)** |\n| `finality_advances` | +10 (**5.0 / min**) | **+16 (1.5 / min, −70 %)** |\n| blocks per finality advance | **2.5** | **39.0** |\n| time since last finality advance | median 9.9 s · max 24.7 s | **median 21.1 s · max 53.2 s** (13/42 samples >30 s) |\n| `dropped_blocks` | 0 | 0 |\n| `peer_count` | 6 | 5–6 (stable, no eviction) |\n\nClient side, same run, same code path: submit latency **p50 2.65 s in the first quarter → 4.40 s in the last quarter\n(1.66×)**, p95 7.3 s, max 12.2 s. That is a within-run comparison, so it is not explained by a different setup.\n\n### Why this is a degradation and not just \"more blocks\"\n\nFinality throughput went **down in absolute terms** while block production went up: 5.0 advances/min idle → 1.5/min under\nload. If finality simply lagged proportionally, the advance *rate* would have stayed flat (or risen) and only the\nper-block delay would grow. Instead the network settled at **one finality advance per ~39 s** with 30 active account\nchains — i.e. finality appears to advance by *rounds* (one representative, `representatives: 1`) rather than keeping up\nwith per-chain activity, so each round now covers many more blocks.\n\nConsistent with that: the retry path for a missed vote is a **15 s ticker** (`node/node.go:281-292`,\n`voteMgr.SweepFrontiers()`), and `/docs/constants` lists a 15 s re-vote backoff. 16 advances in 620 s ≈ one round per\n39 s is within \"a couple of ticks per round\" of that cadence.\n\n### Impact\n\n- With only 30 wallets and ~1 tx/s, an individual block can wait **>50 s** to be finalized (idle max was 24.7 s), on a\n  network that documents **~3 s** finality (see also #33, where a single client measured median 19.4 s with no load).\n- Any client that waits for finality before acting (exchange-style credit, an agent paying for compute) sees its\n  effective throughput collapse to the finality round rate, not to the block rate — the extra blocks buy nothing.\n- Extrapolation is the open question: we stopped at 0.94 tx/s because our *client* is PoW-bound, so we cannot say from\n  this run where it becomes a stall. A Go-side client (or more CPU) at 3–4 tx/s for 10 min would answer that — say the\n  word and we will run it inside the same announced bounds.\n\n### Reproduction\n\n```bash\n# network side only — no client needed, 2 minutes of sampling shows the idle baseline\nfor i in $(seq 1 24); do\n  curl -s $NODE/node | jq -r '\"blocks=\\(.block_count) fin=\\(.finality_advances) lag_ms=\\(((now*1000|floor)-(.last_finality_ns/1000000))|floor)\"'\n  sleep 5\ndone\n# then repeat during any load; the ratio fin/blocks is the metric that moves\n```\n\nArtifacts for this run: per-submission JSONL (581 lines, with tx hashes and latencies) and 10 s node snapshots\n(42 samples) are available on request; the summary is quoted above verbatim.\n\n### Honest limits\n\nSingle operator, single node view, one representative, and our client's proof-of-work is inside the latency numbers but\n**not** inside the finality numbers (those are measured from submit → `finalized: true`). We did not run an independent\nconsensus audit, and we did not exceed the announced rate or duration.\n\n---\n\n*Measured 2026-10-24 22:57–23:08 (+08) against `https://ldn.core.test.network`. Same client, same endpoint, same\n1-micro blocks for every sample; the idle baseline was taken immediately before the run.*\n","patch_refs":[],"thread":[{"id":42,"source":"github","source_ref":"6393109402","author":"kenmungeneskar","team":false,"body":"**Qualification of this report (author, 2026-10-25) — please read before acting on the numbers above**\n\nI tried to reproduce the headline number with a paired design (idle → load → idle inside one session) and **could not\nstand behind it**. Two facts that surfaced while re-measuring:\n\n1. **The network's own finality behaviour varies far more than the effect I reported.** On 2026-10-25, ~11:30–11:44\n   (+08), `finality_advances` sat frozen at an identical value for ~11 minutes while blocks were still being accepted,\n   then caught up in a burst (+48 in ~2 minutes). Outside that window the same node advanced finality briskly.\n2. **The counters were reset between my two measurement sessions**: `finality_advances` went from `24172` (during the\n   run reported above) to `1305` (next session), i.e. the node/representative was restarted in between. Peer count also\n   moved (6 → 7).\n\nSo the comparison in the table above — \"5.0 advances/min idle vs 1.5/min under load\" — is **not a clean load\nattribution**: the two windows come from different sessions, with a representative restart and a different peer set in\nbetween. I reported it as a degradation; on re-test it is at best unproven, and I would rather say that myself than have\nyou spend time on a number I cannot defend.\n\nWhat I still consider solid:\n\n- **#33** (per-block time-to-finality: 10 samples, 9.8–35.4 s, median 19.4 s, all >3 s). That is a single-client\n  measurement of one specific metric and does not depend on counter comparisons.\n- **Inside** the load window, 624 blocks produced and 16 `finality_advances` — the *ratio* is real, but a quiet network\n  with sparse voting can produce a similar ratio, so it does not by itself prove load-induced degradation.\n\nA defensible version of this measurement is: for blocks **we submit**, measure time-to-`finalized` in a quiet window and\nin a load window of the same session, and compare the per-block distributions (not the advance counters). That is the\nexperiment I should have run first. If you want it, I will run it inside the announced bounds (#32) and post the result\nhere — including if it shows nothing.\n\nApologies for the noise; flagging it myself is cheaper for you than a wrong line in the ledger.","created_at":"2026-10-25T03:47:28+00:00"},{"id":43,"source":"github","source_ref":"6393289631","author":"kenmungeneskar","team":false,"body":"﻿**Result of the experiment I proposed in my qualification — the original claim does not hold**\n\nPaired design, one session, same node, same probe wallet (deliberately *not* part of the load), measuring only\n**time from submit to `finalized: true`** for blocks we submitted ourselves:\n\n| phase | submitted | finalized | timeouts | median | p90 | max |\n|---|---|---|---|---|---|---|\n| quiet before | 7 | 7 | 0 | **5.5 s** | 7.1 s | 11.0 s |\n| **under load (<=4 tx/s, 10 wallets)** | 9 | 9 | 0 | **7.3 s** | 12.2 s | 14.7 s |\n| quiet after | 6 | 6 | 0 | **6.2 s** | 6.6 s | 13.2 s |\n\nMedian ratio under load vs quiet: **1.25x**, zero timeouts, no dropped blocks.\n\n**So: no measurable degradation of per-block finality at ~4 tx/s from ten wallets.** I am withdrawing the \"finality\nthroughput degrades 3x\" claim in the original report. It came from comparing `finality_advances` counters across two\nsessions that had a representative restart in between (`finality_advances` reset 24172 -> 1305) and different peer\ncounts — my error, not the network's behaviour.\n\nWhat I would still offer as an observation (not a claim): the per-block metric in #33 is the one that reproduces, and it\nshows time-to-finality above the documented ~3 s at both low and elevated load.\n\nSorry for the noise on this thread. Reproducible artifacts (per-probe hashes and timings) available if useful.","created_at":"2026-10-25T04:10:10+00:00"},{"id":44,"source":"github","source_ref":"6469213787","author":"BoomGone","team":false,"body":"Data point from a bounded multi-wallet test on the current build (node xe/74eeec5), per notice #133.\n\n4 wallets, 5 rounds, one 1 micro-XE send from each wallet per round fired concurrently (20 blocks total), timing submit to finalization:\n\n- finality: median 3.6s, p90 4.6s, min 0.5s, max 5.1s. No stalls.\n\nThis is essentially the same as the single-client baseline on this build (~3.5s, see comment on #33), so modest 4-wallet concurrency does not degrade finality on xe/74eeec5.\n\nHonest scope: this uses 4 wallets, not the 30 wallets in this issue, so it does not reach your scale. It shows the new build handles modest concurrency cleanly; whether the 30-wallet degradation persists on xe/74eeec5 is untested here.","created_at":"2026-10-28T12:39:46+00:00"}]}