TaiJuWu commented on code in PR #20859:
URL: https://github.com/apache/kafka/pull/20859#discussion_r2570278282


##########
raft/src/main/java/org/apache/kafka/raft/KafkaRaftClient.java:
##########
@@ -3372,8 +3393,8 @@ private boolean 
shouldSendAddOrRemoveVoterRequest(FollowerState state, long curr
          * and are configured to auto join should attempt to automatically 
join the voter
          * set for the configured topic partition.
          */
-        return !hasJoined && 
partitionState.lastKraftVersion().isReconfigSupported() && canBecomeVoter
-                && quorumConfig.autoJoin() && 
state.hasUpdateVoterSetPeriodExpired(currentTimeMs);
+        return hasJoined.isPresent() && !hasJoined.get() && 
partitionState.lastKraftVersion().isReconfigSupported()

Review Comment:
   `hasJoined.isPresent` is also mean the local node catch hight watermark, 
right?



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