New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
KAFKA-14499: [1/N] Introduce OffsetCommit API version 9 and add new StaleMemberEpochException error #14046
Conversation
…taleMemberEpochException error
This also leaves us room to add the topic ID to this version if we so choose? |
Yeah, that's right. |
clients/src/main/java/org/apache/kafka/common/requests/OffsetCommitRequest.java
Show resolved
Hide resolved
Something strange is going on with AuthorizerIntegrationTest in the build, but that might be unrelated. I will look into that. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally looks good. Left one small question, but it's mostly my curiosity and nonblocking. Let's confirm the test failures are unrelated.
@jolshan I found the issue related to AuthorizerIntegrationTest failures. I just pushed a fix. See last commit. |
Thanks for the fix @dajac let's just confirm the build and we should be good :) |
@jolshan I was actually thinking about the The Let's take this change as an example. The version 9 will be shipped in the next release even if we don't want to use it because the schema is there. So the client knows about it and may use it if the broker eventually supports the version. The issue is that the release version my be different from the one shipped so the client would get an error. I have updated the |
clients/src/main/resources/common/message/OffsetCommitRequest.json
Outdated
Show resolved
Hide resolved
clients/src/main/java/org/apache/kafka/common/errors/StaleMemberEpochException.java
Show resolved
Hide resolved
I was curious if the unstable version flag was causing issues since I recall some weirdness in tests when I had an unstable version. Makes sense to require the unstable-ness to be explicit, but I will take a second look. |
Looking at the tests Build / JDK 20 and Scala 2.13 / kafka.server.FetchRequestTest.testCurrentEpochValidationV12() is a bit strange but it only failed on that version. Everything else seems to be familiar-ish flakes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for making the unstable versions explicit in the builder now. Changes lgtm
Failed tests are unrelated. Merging to trunk. |
…taleMemberEpochException error (apache#14046) This patch does a few things: 1) It introduces version 9 of the OffsetCommit API. This new version has no schema changes but it can return a StaleMemberEpochException if the new consumer group protocol is used. Note the use of `"latestVersionUnstable": true` in the request schema. This means that this new version is not available yet unless activated. 2) It renames the `generationId` field in the request to `GenerationIdOrMemberEpoch`. This is backward compatible change. 3) It introduces the new StaleMemberEpochException error. 4) It does a minor refactoring in OffsetCommitRequest class. Reviewers: Jeff Kim <jeff.kim@confluent.io>, David Arthur <mumrah@gmail.com>, Justine Olshan <jolshan@confluent.io>
…taleMemberEpochException error (apache#14046) This patch does a few things: 1) It introduces version 9 of the OffsetCommit API. This new version has no schema changes but it can return a StaleMemberEpochException if the new consumer group protocol is used. Note the use of `"latestVersionUnstable": true` in the request schema. This means that this new version is not available yet unless activated. 2) It renames the `generationId` field in the request to `GenerationIdOrMemberEpoch`. This is backward compatible change. 3) It introduces the new StaleMemberEpochException error. 4) It does a minor refactoring in OffsetCommitRequest class. Reviewers: Jeff Kim <jeff.kim@confluent.io>, David Arthur <mumrah@gmail.com>, Justine Olshan <jolshan@confluent.io>
This patch does a few things:
"latestVersionUnstable": true
in the request schema. This means that this new version is not available yet unless activated.generationId
field in the request toGenerationIdOrMemberEpoch
. This is backward compatible change.Committer Checklist (excluded from commit message)