forked from apache/kafka
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
KAFKA-16886: Detect replica demotion in AssignmentsManager (apache#16232
) JBOD Brokers keep the Controller up to date with replica-to-directory placement via AssignReplicasToDirsRequest. These requests are queued, compacted and sent by AssignmentsManager. The Controller returns the error NOT_LEADER_OR_FOLLOWER when handling a AssignReplicasToDirsRequest from a broker that is not a replica. A partition reassignment can take place, removing the Broker as a replica before the AssignReplicasToDirsRequest successfully reaches the Controller. AssignmentsManager retries failed requests, and will continuously try to propagate this assignment, until the Broker either shuts down, or is added back as a replica. When encountering a NOT_LEADER_OR_FOLLOWER error, AssignmentsManager should assume that the broker is no longer a replica, and stop trying to propagate the directory assignment for that partition. Reviewers: Luke Chen <[email protected]>
- Loading branch information
1 parent
e6cfe3f
commit 7cc8597
Showing
2 changed files
with
64 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters