zhijiangW commented on a change in pull request #11351: [FLINK-16404][runtime]
Avoid caching buffers for blocked input channels before barrier alignment
URL: https://github.com/apache/flink/pull/11351#discussion_r409260284
##########
File path:
flink-runtime/src/test/java/org/apache/flink/runtime/io/network/partition/PipelinedSubpartitionWithReadViewTest.java
##########
@@ -353,14 +354,32 @@ private void
testBacklogConsistentWithNumberOfConsumableBuffers(boolean isFlushR
}
}
+ @Test
+ public void testBlockedByCheckpointAndResumeConsumption() throws
IOException, InterruptedException {
+
subpartition.add(createFilledFinishedBufferConsumer(BUFFER_SIZE));
+ subpartition.add(createEventBufferConsumer(BUFFER_SIZE,
Buffer.DataType.EXACTLY_ONCE_CHECKPOINT_BARRIER));
+ subpartition.add(createEventBufferConsumer(BUFFER_SIZE,
Buffer.DataType.EVENT_BUFFER));
+
subpartition.add(createFilledFinishedBufferConsumer(BUFFER_SIZE));
+ subpartition.finish();
+
+ assertNextBuffer(readView, BUFFER_SIZE, true, 1, true, true);
+ assertNextEvent(readView, BUFFER_SIZE, null, false, 1, false,
true);
Review comment:
why we can not verify the real event class here and pass `null` for all the
events, otherwise it is no need to introduce this `expectedEventClass` argument
in `assertNextEvent`
----------------------------------------------------------------
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]
With regards,
Apache Git Services