xinbinhuang commented on code in PR #20289:
URL: https://github.com/apache/flink/pull/20289#discussion_r922891812


##########
flink-connectors/flink-connector-base/src/main/java/org/apache/flink/connector/base/source/hybrid/HybridSourceSplitEnumerator.java:
##########
@@ -258,12 +263,25 @@ private void switchEnumerator() {
             currentSourceIndex++;
         }
 
-        HybridSource.SourceSwitchContext<?> switchContext =
-                new HybridSource.SourceSwitchContext<Object>() {
+        List<SourceSplit> previousSplits =
+                finishedSplits.stream()
+                        .filter(
+                                split ->
+                                        split.isFinished
+                                                && split.sourceIndex() == 
previousSourceIndex)

Review Comment:
   this is a paranoid check..



-- 
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]

Reply via email to