diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/partition/consumer/LocalInputChannel.java b/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/partition/consumer/LocalInputChannel.java index 9a7aa4b96dfc15..5c2000fef58261 100644 --- a/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/partition/consumer/LocalInputChannel.java +++ b/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/partition/consumer/LocalInputChannel.java @@ -666,7 +666,9 @@ private Optional pullPriorityFromSubpartitionView() throw Buffer.DataType expectedNextDataType = next.getNextDataType(); if (!expectedNextDataType.hasPriority()) { - // Reset hasPendingPriorityEvent to false if no more priority event. + // Latent lost-wakeup: this lock-free clear can clobber a concurrent set-true in + // notifyPriorityEvent(). Safe today only because Flink runs no concurrent unaligned + // checkpoints, so at most one priority barrier is ever pending. hasPendingPriorityEvent = false; // Correct nextDataType: if recoveredBuffers is not empty, the actual next element to // consume is from recoveredBuffers, not from subpartitionView.