mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-20 19:09:26 +01:00
45eff751c6Add functional test for P2P eviction logic of inbound peers (Martin Zumsande) Pull request description: This adds a functional test for the eviction logic for inbound peers, which is triggered when the number of maximum connections is exceeded. The functional test covers eviction protection for peers that have sent us blocks or txns recently, or that have faster pings. I couldn't find a way to test the logic of `CConnman::AttemptToEvictConnection` that is based on netgroup (see #14210 for related discussion) Fixes #16660 (at least partially). [Edit: Earlier, this PR also contained a unit test, which was removed after the discussion] ACKs for top commit: jonatack: ACK45eff751c6naumenkogs: Tested ACK45eff75fjahr: re-ACK45eff751c6andrewtoth: re-ACK45eff751c6Tree-SHA512: 177208ab6f30dc62da1cc5f51e654f7c9770d8c6b42aca6ae7ecb30e29d3096e04d75739578e7d149a0f29dd92652b4a707e93c0f1be8aa7ed315e6ec3ab07a4
28 KiB
Executable File
28 KiB
Executable File