Jiayi-Liao commented on a change in pull request #12243:
URL: https://github.com/apache/flink/pull/12243#discussion_r428063945
##########
File path:
flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/io/InputProcessorUtil.java
##########
@@ -79,11 +80,26 @@ public static CheckpointedInputGate
createCheckpointedInputGate(
unionedInputGates[i] =
InputGateUtil.createInputGate(inputGates[i].toArray(new IndexedInputGate[0]));
}
+ IntStream numberOfInputChannelsPerGate =
+ Arrays
+ .stream(inputGates)
+ .flatMap(collection -> collection.stream())
+
.sorted(Comparator.comparingInt(IndexedInputGate::getGateIndex))
+ .mapToInt(InputGate::getNumberOfInputChannels);
+
Map<InputGate, Integer> inputGateToChannelIndexOffset =
generateInputGateToChannelIndexOffsetMap(unionedInputGates);
+ // Note that numberOfInputChannelsPerGate and
inputGateToChannelIndexOffset have a bit different
Review comment:
You're right. I didn't notice that `inputGateToChannelIndexOffset`'s key
is an unioned InputGate. Thanks for pointing this out.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]