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: ensure tokio rt is always dropped on separate task #6191

Merged
merged 1 commit into from
Jan 23, 2024

Conversation

mattsse
Copy link
Collaborator

@mattsse mattsse commented Jan 23, 2024

previously we were dropping the tokio runtime on the current task, as described here:

// drop the tokio runtime on a separate thread because drop blocks until its pools
// (including blocking pool) are shutdown. In other words `drop(tokio_runtime)` would block
// the current thread but we want to exit right away.

this causes issues with blocking tasks (pipeline), so in the panic case we did not always exit right away.

This ensures the tokio rt is always dropped on a separate task so we can exit right away.

@mattsse mattsse requested a review from onbjerg as a code owner January 23, 2024 21:50
@mattsse mattsse requested a review from rkrasiuk January 23, 2024 21:50
@mattsse mattsse added C-bug An unexpected or incorrect behavior A-cli Related to the reth CLI labels Jan 23, 2024
@mattsse mattsse force-pushed the matt/ensure-tokio-rt-is-dropped-on-separate-task branch from ffe9691 to dec3c18 Compare January 23, 2024 21:51
Copy link
Member

@rkrasiuk rkrasiuk left a comment

Choose a reason for hiding this comment

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

🫡

@mattsse mattsse added this pull request to the merge queue Jan 23, 2024
Merged via the queue into main with commit 733d6ce Jan 23, 2024
28 checks passed
@mattsse mattsse deleted the matt/ensure-tokio-rt-is-dropped-on-separate-task branch January 23, 2024 22:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-cli Related to the reth CLI C-bug An unexpected or incorrect behavior
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants