wsry commented on a change in pull request #11877:
URL: https://github.com/apache/flink/pull/11877#discussion_r665080497
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/io/network/netty/CreditBasedPartitionRequestClientHandler.java
##########
@@ -433,8 +459,8 @@ public void operationComplete(ChannelFuture future) throws
Exception {
@Override
public Object buildMessage() {
- return new AddCredit(
- inputChannel.getAndResetUnannouncedCredit(),
inputChannel.getInputChannelId());
+ int credits = inputChannel.getAndResetUnannouncedCredit();
+ return credits > 0 ? new AddCredit(credits,
inputChannel.getInputChannelId()) : null;
Review comment:
I will add a @Nullable annotation.
--
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]