We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8a1d153 commit 09b6857Copy full SHA for 09b6857
kafka-connect-rest-source/src/main/java/org/radarbase/connect/rest/RestSourceTask.java
@@ -74,6 +74,7 @@ public List<SourceRecord> poll() throws InterruptedException {
74
}
75
76
requests = requestGenerator.requests()
77
+ .sequential()
78
.filter(RestRequest::isStillValid)
79
.peek(r -> {
80
logger.info("Requesting {}", r.getRequest().url());
@@ -84,7 +85,7 @@ public List<SourceRecord> poll() throws InterruptedException {
84
85
.filter(Objects::nonNull)
86
.map(s -> s.collect(Collectors.toList()))
87
.filter(l -> !l.isEmpty())
- .findAny()
88
+ .findFirst()
89
.orElse(Collections.emptyList());
90
} while (requests.isEmpty());
91
0 commit comments