Skip to content
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-15705: Add integration tests for Heartbeat API and GroupLeave API #14656

Merged
merged 34 commits into from
Nov 21, 2023

Conversation

dongnuo123
Copy link
Collaborator

This pr is based on #14589,
Adding integration tests for Heartbeat API and GroupLeave API.

JIRA

https://issues.apache.org/jira/browse/KAFKA-15705

Committer Checklist (excluded from commit message)

  • Verify design and implementation
  • Verify test coverage and CI build status
  • Verify documentation (including upgrade notes)

@dajac dajac added the KIP-848 The Next Generation of the Consumer Rebalance Protocol label Oct 27, 2023
Copy link
Contributor

@dajac dajac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dongnuo123 Thanks for the PR. I left some comments.

Copy link
Contributor

@dajac dajac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dongnuo123 Thanks for the update. I left two small comments.

Comment on lines +156 to +159
TestUtils.waitUntilTrue(() => {
val described = describeGroups(groupIds = List("grp"), version = ApiKeys.DESCRIBE_GROUPS.latestVersion(isUnstableApiEnabled))
GenericGroupState.PREPARING_REBALANCE.toString == described.head.groupState
}, msg = s"The group is not in PREPARING_REBALANCE state.")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we should just remove this and wrap the next HB in waitUntilTrue. Have you considered it?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't work because somehow the code in the previous future tend to be executed later than the following code, so I have to set a waitUntilTrue or sleep for a while to make sure the request in the future is processed first.

Copy link
Contributor

@dajac dajac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks.

@dajac dajac merged commit 4ad1d78 into apache:trunk Nov 21, 2023
1 check failed
yyu1993 pushed a commit to yyu1993/kafka that referenced this pull request Feb 15, 2024
AnatolyPopov pushed a commit to aiven/kafka that referenced this pull request Feb 16, 2024
clolov pushed a commit to clolov/kafka that referenced this pull request Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
KIP-848 The Next Generation of the Consumer Rebalance Protocol
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants