KAFKA-20444: [2/N] Update OffsetMetadataManager to use new TxnOffsetCommit errors (KIP-1319)#22214
Merged
dajac merged 1 commit intoapache:trunkfrom May 6, 2026
Merged
Conversation
…ommit errors (KIP-1319) This patch updates `OffsetMetadataManager` to propagate `GROUP_ID_NOT_FOUND` and `STALE_MEMBER_EPOCH` directly starting from version 6 of the `TxnOffsetCommit` API, both at the group lookup and at the per-partition validator. The legacy mapping to `ILLEGAL_GENERATION` is preserved for versions 0 to 5.
chia7712
approved these changes
May 5, 2026
| // facility. In this case, a so-called simple group is created and the request | ||
| // is accepted. | ||
| group = groupMetadataManager.getOrMaybeCreateClassicGroup(request.groupId(), true); | ||
| } else if (TxnOffsetCommitRequest.supportsGroupIdNotFoundError((short) context.requestVersion())) { |
Member
There was a problem hiding this comment.
Not sure why requestVersion uses int rather than short, as header.apiVersion() actually returns a short
Member
Author
There was a problem hiding this comment.
Yeah, not sure why we used an int in AuthorizableRequestContext. It seems to be a mistake to me.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This patch updates
OffsetMetadataManagerto propagateGROUP_ID_NOT_FOUNDandSTALE_MEMBER_EPOCHdirectly starting fromversion 6 of the
TxnOffsetCommitAPI, both at the group lookup and atthe per-partition validator. The legacy mapping to
ILLEGAL_GENERATIONis preserved for versions 0 to 5.
Reviewers: Chia-Ping Tsai chia7712@gmail.com