Github user NicoK commented on a diff in the pull request: https://github.com/apache/flink/pull/4533#discussion_r153447906 --- Diff: flink-runtime/src/main/java/org/apache/flink/runtime/io/network/netty/NettyMessage.java --- @@ -584,4 +587,60 @@ static CloseRequest readFrom(@SuppressWarnings("unused") ByteBuf buffer) throws return new CloseRequest(); } } + + static class AddCredit extends NettyMessage { + + private static final byte ID = 6; + + final ResultPartitionID partitionId; + + final int credit; + + final InputChannelID receiverId; + + AddCredit(ResultPartitionID partitionId, int credit, InputChannelID receiverId) { + this.partitionId = partitionId; + this.credit = credit; --- End diff -- we should probably add a `checkArgument(credit > 1);` here as anything else does not make sense and is wrong, right?
---