AHeise commented on code in PR #159: URL: https://github.com/apache/flink-connector-kafka/pull/159#discussion_r2022304362
########## flink-connector-kafka/src/main/java/org/apache/flink/connector/kafka/sink/internal/ProducerPoolImpl.java: ########## @@ -131,26 +131,33 @@ public void recycleByTransactionId(String transactionalId) { if (!earlierTransactions.isEmpty()) { for (String id : earlierTransactions.values()) { ProducerEntry entry = producerByTransactionalId.remove(id); - recycleProducer(entry.getProducer()); + recycleProducer(entry.getProducer(), false); } earlierTransactions.clear(); } } @Override public void recycle(FlinkKafkaInternalProducer<byte[], byte[]> producer) { - recycleProducer(producer); + recycleProducer(producer, true); ProducerEntry producerEntry = producerByTransactionalId.remove(producer.getTransactionalId()); transactionalIdsByCheckpoint.remove(producerEntry.getCheckpointedTransaction()); } - private void recycleProducer(@Nullable FlinkKafkaInternalProducer<byte[], byte[]> producer) { + private void recycleProducer( Review Comment: Okay I'll try to solve it in that way. -- 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: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org