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

refactor(processor): improve batch processor shutdown and channel handling #421

Merged
merged 2 commits into from
Dec 3, 2024

Conversation

mattevans
Copy link
Member

In an attempt to resolve nil items being run through the batch processor...

WARN[0250] Attempted to build a batch with a nil item. This item has been dropped. This probably shouldn't happen and is likely a bug.  node_record="enode://xx@xx:xx"

... this PR:

  • Refactors channel closure in the batch builder to handle shutdown gracefully
  • Improve queue draining sequence to prevent race conditions during shutdown
  • Wait for in-flight batches to complete before closing channels

@mattevans mattevans self-assigned this Dec 2, 2024
@mattevans mattevans marked this pull request as ready for review December 2, 2024 23:58
@mattevans mattevans requested a review from Savid as a code owner December 2, 2024 23:58
@mattevans mattevans merged commit 12e9090 into master Dec 3, 2024
5 checks passed
@mattevans mattevans deleted the fix/batch-processor-channel-handling branch December 3, 2024 01:00
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