MartijnVisser commented on code in PR #293:
URL:
https://github.com/apache/flink-connector-kafka/pull/293#discussion_r4122360147
##########
flink-connector-kafka/src/main/java/org/apache/flink/connector/kafka/source/reader/fetcher/KafkaSourceFetcherManager.java:
##########
@@ -108,5 +108,10 @@ public boolean run() throws IOException {
@Override
public void wakeUp() {}
});
+
+ // Wake the fetcher so an idle consumer blocked in poll() returns
promptly and runs the
+ // commit task now, instead of leaving the offset uncommitted until
the poll times out.
+ // (On a busy split the next poll will returns straight away, so this
isn't needed)
+ kafkaReader.wakeUp();
Review Comment:
Unlike `addSplits`, this wakes the consumer whatever the fetcher is doing,
split additions included. There `endOffsets` has no `retryOnWakeup` and fails
the fetcher, which I reproduced through `KafkaSourceReader`, and the other
lookups retry only once. I'd drop this, see the thread on test duration.
--
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]