guozhangwang commented on a change in pull request #11362: URL: https://github.com/apache/kafka/pull/11362#discussion_r718738299
########## File path: clients/src/main/java/org/apache/kafka/clients/producer/KafkaProducer.java ########## @@ -704,11 +704,14 @@ public void sendOffsetsToTransaction(Map<TopicPartition, OffsetAndMetadata> offs throwIfInvalidGroupMetadata(groupMetadata); throwIfNoTransactionManager(); throwIfProducerClosed(); - long start = time.nanoseconds(); - TransactionalRequestResult result = transactionManager.sendOffsetsToTransaction(offsets, groupMetadata); - sender.wakeup(); - result.await(maxBlockTimeMs, TimeUnit.MILLISECONDS); - producerMetrics.recordSendOffsets(time.nanoseconds() - start); + + if (offsets.isEmpty()) { Review comment: Ah my bad.. I was trying to fix both on the caller (streams) side as well as the callee (producer) side, but the callee part was added in a last minute and obviously I need some coffee at that time already. -- 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