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

RPC: Fix eth subscription notifications #2812

Merged
merged 7 commits into from
Feb 5, 2024
Merged

Conversation

sieniven
Copy link
Member

@sieniven sieniven commented Feb 2, 2024

Summary

This PR fixes multiple stability issues on the node's subscription system.

  • Switch from unbounded mpsc channel to bounded broadcast channel to safeguard against bloated buffer.
  • Resolve incorrect pipeline of single consumer, used on subscription threads.
  • Implement broadcast receivers in every subscription thread, and trigger response on notifications.
  • Correct handling of errors in each subscription thread, and propagate send results of subscription sink in each thread to ensure proper shutdown.
  • Shift runtime of subscriptions thread to EVM service threadpool.
  • Refactor and clean up param structs.
  • Add config to set notification channel's buffer size (-evmnotificationchannel), defaults to 10_000.
  • Add config to turn on/off Eth subscription notification server (-ethsubscription), defaults to true.

Implications

  • Storage

    • Database reindex required
    • Database reindex optional
    • Database reindex not required
    • None
  • Consensus

    • Network upgrade required
    • Includes backward compatible changes
    • Includes consensus workarounds
    • Includes consensus refactors
    • None

@Bushstar Bushstar merged commit 977c94c into master Feb 5, 2024
15 of 16 checks passed
@Bushstar Bushstar deleted the niven/fix-subscription branch February 5, 2024 14:07
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.

3 participants