Skip to content

fix: eventsource does not reconnect on network error #4247

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Uzlopak
Copy link
Contributor

@Uzlopak Uzlopak commented May 30, 2025

To be honest: I am pretty much confused, why we had this regression. In #2665 the setTimeout got replaced with the non promise one, and thus broke the reconnection logic. It seems like setTimeout from timers/promise without reference, still keeps the process running, but the unref`d normal setTimeout results in letting the process die, even though we are still in reconning state.

Also I dont understand anymore why I wrote the close logic into processEventSourceEndOfBody.

So take this PR with a grain of salt.

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.

1 participant