wangyang0918 commented on code in PR #21742:
URL: https://github.com/apache/flink/pull/21742#discussion_r1100040242
##########
flink-runtime/src/main/java/org/apache/flink/runtime/leaderelection/DefaultLeaderElectionService.java:
##########
@@ -100,6 +100,7 @@ public final void stop() throws Exception {
if (!running) {
return;
}
+ leaderContender.revokeLeadership();
Review Comment:
> Essentially, leadership can be revoked by the HA backend or by itself when
calling `stop`.
This make sense to me. Then I agree to call the `onRevokeLeadership()` as
part of the `DefaultLeaderElectionService.stop()`. It means the leader
information stored in the ZNode/ConfigMap will be cleared when the contender is
stopping. This should be the expected behavior.
--
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]