amaliujia commented on code in PR #1647:
URL: https://github.com/apache/ratis/pull/1647#discussion_r4345232947


##########
ratis-server/src/main/java/org/apache/ratis/server/impl/RaftServerImpl.java:
##########
@@ -299,10 +300,12 @@ public long[] getFollowerMatchIndices() {
         id + "-client");
     this.threadGroup = new ThreadGroup(proxy.getThreadGroup(), 
getMemberId().toString());
 
-    this.closeFuture.whenComplete((v, e) -> {
+    this.closeFuture.whenComplete((allServers, e) -> {
       // A division closed before its role is initialized has no role info to 
report.
       if (role.getCurrentRole() != null) {
-        stateMachine.event().notifyServerShutdown(getRoleInfoProto(), false);
+        // allServers is null when the close has failed.

Review Comment:
   @szetszwo do you think if we actually need a 
   ```
   if (allServers == null) || e != null) {
      // add a status EventStatus.FAILED and post this status?
   }
   ```



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