ivandika3 commented on code in PR #1647:
URL: https://github.com/apache/ratis/pull/1647#discussion_r4320704544
##########
ratis-server/src/main/java/org/apache/ratis/server/impl/RaftServerProxy.java:
##########
@@ -125,6 +125,9 @@ public synchronized void close() {
return;
}
isClosed = true;
+ // Notify all the state machines upfront: the close tasks submitted
below each wait for the committed entries
+ // to be applied, so a task queued behind them could otherwise be
delayed for an unbounded time.
+ map.values().forEach(f -> f.thenAccept(impl ->
impl.notifyServerShutdownInitiated(true)));
Review Comment:
The subsequent `close` under `parallelForEachAsync` also called
`notifyServerShutdownInitiated`, is this a duplicate?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]