dgb(phase-b): feed stratum work template from embedded mempool [surface-for-tap] - #322
Merged
Merged
Conversation
…mpool Wire DGBWorkSource::get_current_work_template to select fee-sorted mempool transactions via the make_mempool_tx_source SSOT (BLOCK_MAX_WEIGHT cap), mirroring the embedded node path (#248). The selection shapes GBT transactions[] and its fee total folds into coinbasevalue through the #207 resolve_coinbase_value SSOT; the builder passes the array through verbatim. On the current empty embedded mempool the call yields an empty transactions[] and total_fees=0 -- byte-identical to the prior coinbase-only template. It lights up unchanged once the embedded P2P mempool feed populates the pool. DGB-tree only; shared modules untouched. dgb_share_test 26/26, block_assembly 8/8, mempool_ingest 5/5; c2pool-dgb links.
frstrtr
added a commit
that referenced
this pull request
Jun 23, 2026
…pool-feed dgb(phase-b): feed stratum work template from embedded mempool [surface-for-tap]
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Phase B pool/share slice. Wires
DGBWorkSource::get_current_work_templateto feed its served GBT template from the in-process embedded Mempool via themake_mempool_tx_sourceSSOT (BLOCK_MAX_WEIGHT cap), mirroring the embedded node path (#248). Fee-sorted txs shapetransactions[]; their fee total folds intocoinbasevaluethrough the #207resolve_coinbase_valueSSOT.Byte-identical today: on the current empty embedded mempool the selection yields an empty
transactions[]and total_fees=0 -- identical to the prior coinbase-only template. It lights up unchanged once the embedded P2P mempool feed populates the pool.Fencing: DGB tree only (
src/impl/dgb/stratum/work_source.cpp), shared modules untouched. Consensus-VALUE-bearing when the mempool is non-empty -> surfaced for operator tap, NOT auto-merge.Tests: dgb_share_test 26/26, dgb_block_assembly_test 8/8, dgb_mempool_ingest_test 5/5; c2pool-dgb links clean.