-
Notifications
You must be signed in to change notification settings - Fork 182
V2.1.0 #174
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
Conversation
Subscriptions and Dispatchers can drain. Connections can drain. Added several tests for main and exceptional cases. Fixed #170
Only upload snapshot from oracle jdk 8.
Updated dependency for NKey to implementation
Added support for drain in message queue Added callback after unsub/flush to mark message queue Improved flush timeout behavior Added timeout to drain if unsub/flush times out Added several tests for drain and flush Removed support for R/R during drain Converted natsbench to throttling - it was failing More doc
fixed wrong exception from get private key
…gs on reconnect. This is hard to test but likely happens when pings are sent during a slower reconnect. Added a check for the null pointer. Added a check to not ping the server if not connected (in the ping timer). Fixes #172
Updated readme Fixed issue in travis Updated changelog
| * messages have reached the server. | ||
| * Finally the connection is closed. | ||
| * | ||
| * In order to drain subscribers, an unsub is sent to the server followed by a flush. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick. Maybe say UNSUB protocol message?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
| * were drained in the timeout, and false otherwise. The future is completed after the connection | ||
| * is closed, so any connection handler notifications will happen before the future completes. | ||
| * | ||
| * @param timeout The time to wait for the drain to succeed, pass 0 to wait |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In other languages we use -1 for "forever".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since we don't support 0 time, i think this is ok. Also, changing would require a major revision bump.
| try { | ||
| reply = incoming.get(timeout.toNanos(), TimeUnit.NANOSECONDS); | ||
| } catch (ExecutionException|TimeoutException e) { | ||
| } catch (ExecutionException | TimeoutException e) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you intend to leave interrupted and cancellation exceptions uncaught?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, interrupted exceptions should rarely be eaten as they tell the caller the thread was interrupted. Cancellation has the same meaning here for the future, so we don't want to eat it.
ColinSullivan1
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Support for Drain on the connection and Subscription.
Fixed a null pointer in certain situations with ping/reconnect
Added more JDKs to travis build
Bumping version number for added drain API.