C0urante commented on code in PR #14763:
URL: https://github.com/apache/kafka/pull/14763#discussion_r1414180940
##########
connect/runtime/src/main/java/org/apache/kafka/connect/util/KafkaBasedLog.java:
##########
@@ -222,6 +227,21 @@ protected Producer<K, V> createProducer() {
protected Consumer<K, V> createConsumer() {
return consumer;
}
+
+ @Override
+ protected boolean readPartition(TopicPartition topicPartition) {
+ return readTopicPartition.test(topicPartition);
+ }
+
+ @Override
+ public void stop() {
+ super.stop();
+ // Close the clients here, if the thread that was responsible
for closing them was never started.
+ if (thread == null) {
Review Comment:
IMO this check isn't necessary; `close` is idempotent for producers and
consumers.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]