rusk icon indicating copy to clipboard operation
rusk copied to clipboard

node: Extend GetResource message flow to provide Candidate block

Open goshawk-3 opened this issue 9 months ago • 0 comments

Summary

💡 Use "Flooding with Random Walk" impl (if beneficial for) in GetCandidate message flow.

Context: GetCandidate P2P message is currently used in creating the winner block in consensus task on Quorum message arrival. It sends request to 7 random (alive) peers and waits for a response 2s. Together with that, GetCandidate search for block only in Candidates Column Family but it could also check the Ledger CF too.

Possible solution design or implementation

  • Deprecate GetCandidate message flow.
  • Extend GetResource msg flow to support CandidateFromHash Inventory type
  • Extend handle_get_candidate to search for a missing candidate in Ledger Column family

Additional context

GetResource (BlockFromHash) (called in Chain component on arrival of Quorum msg) overlaps with GetCandidate request.

depends on https://github.com/dusk-network/rusk/pull/1711

goshawk-3 avatar May 08 '24 09:05 goshawk-3