Skip to content

Commit 863d351

Browse files
shibdnikhil-ctds
authored andcommitted
[improve][io] Remove sleep when sourceTask.poll of kafka return null (apache#24124)
(cherry picked from commit d0c996e) (cherry picked from commit 0782b7d)
1 parent 5f675b0 commit 863d351

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

pulsar-io/kafka-connect-adaptor/src/main/java/org/apache/pulsar/io/kafka/connect/AbstractKafkaConnectSource.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,6 @@ public synchronized Record<T> read() throws Exception {
169169
flushFuture = new CompletableFuture<>();
170170
List<SourceRecord> recordList = sourceTask.poll();
171171
if (recordList == null || recordList.isEmpty()) {
172-
Thread.sleep(1000);
173172
continue;
174173
}
175174
outstandingRecords.addAndGet(recordList.size());

0 commit comments

Comments
 (0)