Skip to content

feat(core/stratum): per-session doa_shares_ DOA counter (split from #665)#666

Merged
frstrtr merged 1 commit into
masterfrom
ltc-doge/stratum-doa-share-accounting
Jul 11, 2026
Merged

feat(core/stratum): per-session doa_shares_ DOA counter (split from #665)#666
frstrtr merged 1 commit into
masterfrom
ltc-doge/stratum-doa-share-accounting

Conversation

@frstrtr

@frstrtr frstrtr commented Jul 11, 2026

Copy link
Copy Markdown
Owner

Split out of #665 per the integrator scope ruling (test-harness PR must not carry a shared-src/core prod change).

What

Increments a new per-session doa_shares_ counter in StratumSession::handle_submit on the block-template-changed path (live-vs-frozen prevhash mismatch at submit).

  • Accounting only — the share is still created and broadcast (matches p2pool). No PPLNS/consensus path touched.
  • Sits alongside the existing accepted_/rejected_/stale_shares_ session stat members.

Scope justification (src/core = shared exceptional-only lane)

Per-session DOA visibility for the crossing-soak dashboards. Isolated to StratumSession stat members; no coin-specific consensus, no isolation-primitive (prefix/id) touched.

Honest caveats for the reviewer

  • Write-only today: the counter is incremented but not yet read by any dashboard/stats endpoint. If you would rather this land together with its consumer, hold it and I will fold it into the dashboard-emit change instead. Flagging rather than hiding.
  • Gate: needs all four coin smokes green before merge (shared-lane rule).

Not in this diff

The SPDX AGPL headers and the no-trailing-newline state on both files are already on master from relicense #658 — they are not introduced here. git diff github/master...03e3a6eb -- src/core/stratum_server.* shows only the two doa_shares_ lines.

GPG: signed, key 50AB1379285EFE76.

…-changed submit

Split out of #665 (threetier wirecompat harness) per the integrator scope ruling:
src/core is the shared exceptional-only lane, so this prod-accounting change must
travel as its own reviewable diff rather than ride a test-harness PR.

Increments doa_shares_ in StratumSession::handle_submit when the block template
changed between job issue and submit (live-vs-frozen prevhash mismatch). Accounting
only: the share is still created and broadcast (matches p2pool); no PPLNS/consensus
path touched. NOTE: counter is currently write-only (no dashboard consumer yet).

Requires an explicit justification + all four coin smokes green before merge.
@frstrtr
frstrtr merged commit 7294c68 into master Jul 11, 2026
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant