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

Design better connection handling for Connection and Notification stream #36

Open
relu91 opened this issue Jan 12, 2023 · 0 comments
Open

Comments

@relu91
Copy link
Contributor

relu91 commented Jan 12, 2023

After fdb25ca, we removed the forwarding of errors from ws of a Connection to NotificationStream. This caused a set of problems with users trying to re-subscribe when a Subscription failed. In particular, since the connection error was forwarded before the catch close in the connect function inside notificationStream method, the connection object was not cleanly closed and it started reconnecting without control. Furthermore, it was impossible to invalidate the connection inside the connectionPool because the new connection was created before the clean-up function in the error handler (the error handler cannot be registered before the one that fire the initial error).

In future releases, we should spend time to rethink once again the process of connection control in our API.

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

No branches or pull requests

1 participant