wsry commented on a change in pull request #11877:
URL: https://github.com/apache/flink/pull/11877#discussion_r665068048
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/io/network/partition/consumer/RemoteInputChannel.java
##########
@@ -357,11 +359,26 @@ public void resumeConsumption() throws IOException {
checkState(!isReleased.get(), "Channel released.");
checkPartitionRequestQueueInitialized();
+ if (initialCredit == 0) {
+ unannouncedCredit.set(0);
Review comment:
This because RemoteInputChannel#notifyBufferAvailable which increases
```unannouncedCredit``` and floating buffer assignment is not an atomic
operation. There is a possibility:
1. the floating buffer is assigned;
2. the floating buffer is released because of receiving an event which
blocks the channel;
3. the notifyBufferAvailable is called and the unannouncedCredit is
increased.
Do you mean we should make RemoteInputChannel#notifyBufferAvailable and
floating buffer assignment an atomic operation?
--
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]