-
Notifications
You must be signed in to change notification settings - Fork 150
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
NatsConnection.close unnecessarily sleeps for one second #310
Comments
Haven't dug into logic, but wanted to make a quick note, in case someone else digs in, but we shouldnt' use get(), there should always be a timeout on these. That said, if we are always reaching the timeout, that is bad. |
@sasbury The code does use |
Any news on this issue? |
The read call is blocking. We can actually interrupt the read by telling the underlying socket to shutdown. Is this the desired behavior to basically forcibly stop the read? Here is a PR to review: #427 |
Closed in #427 |
This call to NatsConnectionReader.stop simply sets a flag, but it does not actually interrupt the blocking read, which means that this call to await the stop always times out. Commit bb8968b recently removed the logging that happens when the await fails, but the underlying issue is still present. It seems like these calls to
.get
should be removed, and these these calls should be updated to usereadStop.get
andwriteStop.get
.The text was updated successfully, but these errors were encountered: