ascherbakoff commented on code in PR #4821:
URL: https://github.com/apache/ignite-3/pull/4821#discussion_r1897235503


##########
modules/raft/src/main/java/org/apache/ignite/internal/raft/server/impl/JraftServerImpl.java:
##########
@@ -447,6 +447,10 @@ public boolean startRaftNode(
             // Thread pools are shared by all raft groups.
             NodeOptions nodeOptions = opts.copy();
 
+            // Then a new election starts on a node, it has local physical 
time higher than last generated safe ts
+            // because we wait out the clock skew.
+            
nodeOptions.setElectionTimeoutMs(Math.max(nodeOptions.getElectionTimeoutMs(), 
groupOptions.maxClockSkew()));

Review Comment:
   I've investigated this scenario and ensured everything is ok, because:
   1. Then a configuration is changed from A to B, on new configuration commit 
A steps down and sends timeoutnowrequest to B
   2. If it dies before sending the request, B will elect self a leader after 
previos leader (A) lease timeout.
   
   Added a new test for this scenario: 
org.apache.ignite.distributed.ReplicasSafeTimePropagationTest#testSafeTimeReorderingOnClusterShrink



-- 
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: notifications-unsubscr...@ignite.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to