HomePhabricator

[avalanche] Don't rely on the service bit for sending the avalanche message

Description

[avalanche] Don't rely on the service bit for sending the avalanche message

Summary:
This leverage the avahello message to determine if a peer has avalanche enabled rather than relying on the service bit or the ability to ignore the unsupported messages. This will let poll only nodes (that don't set the service bit) participate in the address and compact proof messaging.

Sending the getavaaddr and getavaproofs are now sent upon reception of the avahello message instead of the version message.

The tests are updated in a way that makes them closer to the actual real use case: the nodes are non longer connected via RPC but use the regular peer discovery mechanism instead.

Depends on D11723.

Test Plan:

ninja all check-all

Reviewers: #bitcoin_abc, deadalnix, sdulfari

Reviewed By: #bitcoin_abc, deadalnix, sdulfari

Subscribers: sdulfari, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D11701

Details

Provenance
FabienAuthored on Jul 4 2022, 19:58
FabienPushed on Jul 15 2022, 09:30
Reviewer
Restricted Project
Differential Revision
D11701: [avalanche] Don't rely on the service bit for sending the avalanche message
Parents
rABCb562de8831b1: use m_chain in CChainState::UpdateFlagsForBlock and CChainState::FinalizeBlock
Branches
Unknown
Tags
Unknown