jolshan commented on code in PR #13036: URL: https://github.com/apache/kafka/pull/13036#discussion_r1055725758
########## core/src/test/scala/integration/kafka/api/TransactionsExpirationTest.scala: ########## @@ -129,9 +129,11 @@ class TransactionsExpirationTest extends KafkaServerTestHarness { producer.flush() // Ensure producer IDs are added. - val pState = producerState - assertEquals(1, pState.size) - val oldProducerId = pState(0).producerId + var pState : List[ProducerState] = null + TestUtils.waitUntilTrue(() => { pState = producerState; pState.nonEmpty}, "Producer IDs for topic1 did not propagate quickly") + assertEquals(1, pState.size, "Unexpected producer to topic1") Review Comment: Ah ok -- that makes sense. I guess there's no crazy race where it would expire again now. :) -- 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