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-14562 [2/3]: Implement epoch bump after every transaction (KIP-…
…890) (apache#17402) This patch includes changes to the clients end transaction response handling when transaction version 2 is enabled. Version 5+ of the End Txn Response includes the producer Id and the producer epoch fields. Upon receiving the request, the client updates its producer Id and epoch according to the response. On receiving an EndTxnRequest the server would've either: Bumped the epoch for the given producer ID. On epoch overflow, sent a new producer Id with epoch 0. This patch also includes changes to the endTxnRequest to send the right request version based on whether txnV2 is enabled. There was a test failure in the integration tests that allowed us to catch a bug in the PrepareComplete method where we update the transit metadata incorrectly. Added the bug fix in this patch where the lastProducerEpoch is updated correctly. Reviewers: Artem Livshits <[email protected]>, Justine Olshan <[email protected]>
- Loading branch information
Showing
17 changed files
with
484 additions
and
79 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
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
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
Oops, something went wrong.