sanpwc commented on code in PR #4950:
URL: https://github.com/apache/ignite-3/pull/4950#discussion_r1895371329


##########
modules/raft/src/main/java/org/apache/ignite/raft/jraft/core/FSMCallerImpl.java:
##########
@@ -542,6 +546,8 @@ private void doCommitted(final long committedIndex) {
             if (iterImpl.hasError()) {
                 setError(iterImpl.getError());
                 iterImpl.runTheRestClosureWithError();
+            } else if (shuttingDown) {
+                iterImpl.runTheRestClosureWithShutdownException();
             }
             final long lastIndex = iterImpl.getIndex() - 1;

Review Comment:
   Hmm, seems that there are some minor leaks. Let's say we have concurrent 
disasterRecovery procedure that is trying to find out most up-to-date raft node 
(node with max log index). It reads "incorrect" lastLogId and returns it to the 
requester. It look like a minor suboptimality of disaster recovery procedure. 
Though it might be solved by returning last persisted log id if node is 
shutting down. 



-- 
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]

Reply via email to