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 1-worker underflow; lower default batch size #13734

Merged
merged 2 commits into from
Mar 14, 2024
Merged

Conversation

kasey
Copy link
Contributor

@kasey kasey commented Mar 12, 2024

What type of PR is this?

Bug fix
Other

What does this PR do? Why is it needed?

This PR fixes a panic that occurs soon after the first backfill batch completes, if the backfill worker count flag is set to 1 (--backfill-worker-count=1).

Also, the default value for --backfill-batch-size is lowered from 64 to 32, based on testing in mainnet where it was observed that this value led to a healthier mix of peer implementations, due to the higher batch size triggering rate limits more frequently for some peer implementations.

@kasey kasey requested a review from a team as a code owner March 12, 2024 22:37
@@ -79,6 +79,10 @@ func (c *batchSequencer) update(b batch) {
// so we want to copy c to a, then on i=3, d to b, then on i=4 e to c.
c.seq[i-done] = c.seq[i]
}
if done == 1 && len(c.seq) == 1 {
Copy link
Member

Choose a reason for hiding this comment

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

is it possible to test for this ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

added a test

@nisdas nisdas added this pull request to the merge queue Mar 14, 2024
Merged via the queue into develop with commit 9fcb9b8 Mar 14, 2024
17 checks passed
@nisdas nisdas deleted the backfill-fixes branch March 14, 2024 01:24
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