-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
connectTimeout and reconnectPeriod interaction #419
Comments
Yes, that would be awesome. Please send a PR! |
Closing with no activity. Feel free to reopen if this is still a bug for you. |
Has anything been done to address the bug? Apologies for not following up with a pr by now, but this is a real issue. |
Unfortunately not, would you mind to send a PR, or at least add a quick unit test to reproduce? Those are tricky to produce :(. |
is this still a bug? I'm trying to understand what causes the client to "close" then "end" and then "reconnect" after certain amount of time... |
@burritoIand this is still a bug. we still need to address this. |
This would appear to take significant amount of work to disentangle the two. It would also look to require work with refactoring the state machine to be more... legitimate. So we are still waiting to get to this. |
@knolleary Would you mind to submit a PR to fix this? |
I tried to reproduce this but it seems to have been fixed by #1779, specifically the change that fixed this issue was: |
If
reconnectPeriod
is set to 60 seconds (for example) but theconnectTimeout
left at the default 30 seconds, the reconnect attempt will be abandoned after 30 seconds and it will no longer keep trying to connect. Crucially, the application doesn't know this has happened and assumes the reconnect attempts will continue but they don't.I believe the right approach is to clear the connectTimeout timer if the TCP connection fails, as that is already being handled by the reconnect logic.
Raising this for discussion/placeholder - can put together a PR later this week if agreed.
The text was updated successfully, but these errors were encountered: