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

Be less aggresive when churning peers #4656

Merged
merged 2 commits into from
Aug 24, 2023

Conversation

karknu
Copy link
Contributor

@karknu karknu commented Aug 24, 2023

Be less aggresive when churning established and known peers. Active peers are established peers and established peers are known peers. This means that when churning established peers and known peers we where churning too many peers.

This patch changes the churn behaviour so that we aim to only churn 20% of the established peers that are not also hot peers, and 20% of the known peers that are not also established peers.

This makes it possible to run the node with fewer established peers which reduces the overall number of connections in the network.

Description

description of the pull request, if it fixes a particular issue it should link the PR to a particular issue, see ref

Checklist

  • Branch
    • Updated changelog files.
    • Commit sequence broadly makes sense
    • Commits have useful messages
    • The documentation has been properly updated
    • New tests are added if needed and existing tests are updated
    • If serialization changes, user-facing consequences (e.g. replay from genesis) are confirmed to be intentional.
  • Pull Request
    • Self-reviewed the diff
    • Useful pull request description at least containing the following information:
      • What does this PR change?
      • Why these changes were needed?
      • How does this affect downstream repositories and/or end-users?
      • Which ticket does this PR close (if any)? If it does, is it linked?
    • Reviewer requested

Be less aggresive when churning established and known peers.
Active peers are established peers and established peers are known
peers. This means that when churning established peers and known peers
we where churning too many peers.

This patch changes the churn behaviour so that we aim to only churn 20%
of the established peers that are not also hot peers, and 20% of the
known peers that are not also established peers.

This makes it possible to run the node with fewer established peers
which reduces the overall number of connections in the network.
@karknu karknu requested a review from coot as a code owner August 24, 2023 09:40
Copy link
Contributor

@coot coot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM; there's just something wrong with the CHANGELOG.md file.

ouroboros-network/CHANGELOG.md Outdated Show resolved Hide resolved
Mention less churning of established and known peers.
@karknu karknu force-pushed the karknu/churn_20_m branch from 7d27ea3 to 7b697fd Compare August 24, 2023 12:02
Copy link
Contributor

@coot coot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @karknu.

@coot coot added this pull request to the merge queue Aug 24, 2023
Merged via the queue into IntersectMBO:master with commit a9ca17b Aug 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants