Page MenuHomePhabricator

[avalanche] Send getavaproofs periodically to one random peer
ClosedPublic

Authored by Fabien on Jun 10 2022, 14:55.

Details

Summary

The getavaproofs requests are only requested upon connection for now, let send more on a regular basis. This will help keeping up to date even if we don't connect to new peers.

Depends on D11612.

Test Plan
./test/functional/test_runner.py abc_p2p_compactproofs

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Fabien requested review of this revision.Jun 10 2022, 14:55
sdulfari requested changes to this revision.Jun 10 2022, 18:17
sdulfari added a subscriber: sdulfari.
sdulfari added inline comments.
src/net_processing.cpp
1708 ↗(On Diff #33967)

No need to shuffle if avanode_outbound_ids is empty

test/functional/abc_p2p_compactproofs.py
102 ↗(On Diff #33967)

Can this be flaky? Should it be changed to >= 1?

This revision now requires changes to proceed.Jun 10 2022, 18:17
src/net_processing.cpp
1708 ↗(On Diff #33967)

In this case it will be a no op, so I don't see a reason to special case the empty vector

test/functional/abc_p2p_compactproofs.py
102 ↗(On Diff #33967)

It should be ok as long as the test lasts less than 2 minutes, but you're right >= 1 is more correct here

Don't assume the test duration

This revision is now accepted and ready to land.Jun 10 2022, 20:41