mwesterby commented on code in PR #23639:
URL: https://github.com/apache/kafka/pull/23639#discussion_r4492993434
##########
metadata/src/main/java/org/apache/kafka/controller/QuorumController.java:
##########
@@ -1266,6 +1266,16 @@ public void processBatchEndOffset(long offset) {
}
}
+ public CompletableFuture<Void> forceRenounce() {
+ CompletableFuture<Void> future = new CompletableFuture<>();
+ appendControlEvent("forceRenounce", () -> {
+ if (isActiveController())
+ renounce();
+ future.complete(null);
+ });
+ return future;
+ }
+
Review Comment:
> am I right to say here that forceRenounce renounces whichever epoch is
current when the event runs, not the epoch where the driver saw the conflict?
Yes this would be correct, and could lead to an unnecessary election. I
think we should be able to pass the epoch value the driver saw during the
conflict to `forceRenounce` as you mention, and then only resign if they match.
It may be a larger change but I will take a look.
--
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]