Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(blocksync): sort peers by download rate & multiple requests for …
…closer blocks (cometbft#2475) It can be reviewed commit by commit. 1. Request the block N from peer B immediately after getting `NoBlockResponse` from peer A cometbft@a718fb4 2. Sort peers by download rate (the fastest peer is picked first) cometbft@cf19851 3. Request a block from peer B if we are approaching pool's height (less than 50 blocks) and the current peer A is slow in sending us the block cometbft@e06ebfe cometbft@e97007f Closes cometbft#2379 ### Benchmarks Osmosis: without this PR (baseline): 11.45m with this PR: 7.29m ~ 36% decrease --- #### PR checklist - [x] Tests written/updated - [x] Changelog entry added in `.changelog` (we use [unclog](https://github.com/informalsystems/unclog) to manage our changelog) - [x] Updated relevant documentation (`docs/` or `spec/`) and code comments - [x] Title follows the [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) spec
- Loading branch information