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

fix(p2p): set gossipsub buffersize to avoid missed blocks #975

Merged
merged 5 commits into from
Jul 22, 2024

Conversation

srene
Copy link
Contributor

@srene srene commented Jul 19, 2024

PR Standards

Opening a pull request should be able to meet the following requirements

--

PR naming convention: https://hackmd.io/@nZpxHZ0CT7O5ngTp0TP9mg/HJP_jrm7A


Close #972

<-- Briefly describe the content of this pull request -->

There is a channel in gossipsub implementation, used to consume packets received, that its default size is 32.
If the occupancy goes over the limit, packets are not added and dropped.
By setting a bigger buffer size for the channel we limit the problem, which was happening in cases where out of sync full-nodes where trying to apply long list of blocks, while receiving them from p2p at fast rate.

For Author:

  • Targeted PR against correct branch
  • included the correct type prefix in the PR title
  • Linked to Github issue with discussion and accepted design
  • Targets only one github issue
  • Wrote unit and integration tests
  • All CI checks have passed
  • Added relevant godoc comments

For Reviewer:

  • confirmed the correct type prefix in the PR title
  • Reviewers assigned
  • confirmed all author checklist items have been addressed

After reviewer approval:

  • In case targets main branch, PR should be squashed and merged.
  • In case PR targets a release branch, PR should be rebased.

@srene srene requested a review from a team as a code owner July 19, 2024 10:05
@mtsitrin mtsitrin merged commit 0d3be11 into main Jul 22, 2024
6 checks passed
@mtsitrin mtsitrin deleted the srene/972-p2p-gossip-fix-buffer branch July 22, 2024 10:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

p2p gossiped blocks lost when applying batches from DA
4 participants