dajac commented on code in PR #15492: URL: https://github.com/apache/kafka/pull/15492#discussion_r1539493833
########## core/src/test/scala/unit/kafka/server/GroupCoordinatorBaseRequestTest.scala: ########## @@ -73,6 +74,17 @@ class GroupCoordinatorBaseRequestTest(cluster: ClusterInstance) { ) } + protected def alterConsumerGroupOffsets( + groupId: String, + offsets: Map[TopicPartition, OffsetAndMetadata] + ): Unit = { + val resultFuture = cluster.createAdminClient().alterConsumerGroupOffsets(groupId, offsets.asJava).all + + TestUtils.waitUntilTrue(() => { + resultFuture.isDone && !resultFuture.isCancelled && !resultFuture.isCompletedExceptionally + }, msg = s"Could not commit the offsets successfully. Last response ${resultFuture.get()}.") Review Comment: Hum... `.get` will throw the exception if the future is completed exceptionally or timed out. It should be enough, no? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org