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

Manual disconnect doesn't block reconnecting #374

Open
jexjang opened this issue Nov 6, 2023 · 2 comments
Open

Manual disconnect doesn't block reconnecting #374

jexjang opened this issue Nov 6, 2023 · 2 comments

Comments

@jexjang
Copy link

jexjang commented Nov 6, 2023

Unable to Disconnect Manually

There seems to be no direct method to manually disconnect. When invoking the disconnect method on the client struct, it does trigger an actual disconnection.
However, the reconnection mechanism remains active, which results in the client attempting to reconnect immediately after disconnection.

This issue can be circumvented by setting the reconnect attribute to false in the ClientBuilder, but this solution is not viable for my use case. I need the client to automatically reconnect in the event of an accidental disconnection, not a manual one.

Is there a way to manually disconnect the client such that it doesn't attempt to reconnect, while still retaining the automatic reconnection capability in cases of unintentional disconnections?

@jexjang
Copy link
Author

jexjang commented Nov 6, 2023

Even if the Client is dropped after the disconnection, the reconnection mechanism stays alive.

@tobegreen
Copy link

Will this also allow to kill the connection and reinstate with new authentication credentials? Currently we want to be able to disconnect and restart with new authentication parameters, but still reconnect on disconnect events. Will this allow that flow?

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

2 participants