Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Init-sync: enable peer scorer by default #7974

Merged
merged 13 commits into from
Dec 3, 2020

Conversation

farazdagi
Copy link
Contributor

What type of PR is this?

Other / Feature Release

What does this PR do? Why is it needed?

  • Peer scorer in init-sync was enabled in --dev for months, so relatively it is much more stable than peer scoring in p2p and/or gossip (which are protected by the very same --enable-peer-scorer flag).
  • The purpose of peer scorer in init-sync was to probabilistically select peers that provide better data: if data provided by peer moves head forward well (on average), peer's score gets increased, and peer gets better chances to get selected.
  • The problem with ineffective peers was amplified on altona when some clients returned 1 block (or few blocks), and sync was becoming really slow. With peer scorer such ineffective peers can still be selected, but with lesser chances (weighted random selection).
  • After discussing with @nisdas we decided to release this part of peer scorer separately, w/o waiting for other types or scoring (to make sure that init sync process is more effective). Since scorers are quite cohesive, and can be used independently, we do not have to couple init-sync scorer's release cycle and that of other types of scoring. It is ready, and has been tested running for long time in --dev mode.

Which issues(s) does this PR fix?

N/A

Other notes for review

@farazdagi farazdagi added the Ready For Review A pull request ready for code review label Nov 26, 2020
@farazdagi farazdagi self-assigned this Nov 26, 2020
@farazdagi farazdagi requested a review from a team as a code owner November 26, 2020 18:59
@farazdagi farazdagi added this to the v1.1.0 milestone Nov 26, 2020
@farazdagi farazdagi added the Sync Sync (regular, initial, checkpoint) related issues label Nov 29, 2020
@rauljordan rauljordan changed the base branch from master to develop November 30, 2020 21:39
@farazdagi farazdagi marked this pull request as draft December 1, 2020 17:18
@farazdagi farazdagi marked this pull request as ready for review December 1, 2020 17:18
@rkapka rkapka modified the milestones: v1.0.3, v1.1.0 Dec 2, 2020
@farazdagi farazdagi modified the milestones: v1.1.0, v1.0.4 Dec 2, 2020
@prylabs-bulldozer prylabs-bulldozer bot merged commit 5417e8c into develop Dec 3, 2020
@delete-merged-branch delete-merged-branch bot deleted the release-init-sync-peer-scorer branch December 3, 2020 00:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ready For Review A pull request ready for code review Sync Sync (regular, initial, checkpoint) related issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants