AHeise commented on a change in pull request #11507: [FLINK-16587] Add basic CheckpointBarrierHandler for unaligned checkpoint URL: https://github.com/apache/flink/pull/11507#discussion_r408162902
########## File path: flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/io/CheckpointedInputGate.java ########## @@ -171,6 +176,18 @@ else if (bufferOrEvent.getEvent().getClass() == CancelCheckpointMarker.class) { } } + public List<Buffer> requestInflightBuffers(long checkpointId, int channelIndex) throws IOException { + if (((CheckpointBarrierUnaligner) barrierHandler).hasInflightData(checkpointId, channelIndex)) { + return inputGate.getChannel(channelIndex).requestInflightBuffers(checkpointId); Review comment: When a barrier is received in the input channel, it triggers the notify, but is also added at the tail of the queue in its in-order position. `hasInflightData` is only updated to `false` in `Unaligner#processBarrier` when task thread pulls the barrier from its in-order position. That means, that `hasInflightData` can only be false iff `X` has been consumed in the meantime. ---------------------------------------------------------------- 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: us...@infra.apache.org With regards, Apache Git Services