zhijiangW commented on a change in pull request #8654: [FLINK-12647][network] 
Add feature flag to disable release of consumed blocking partitions
URL: https://github.com/apache/flink/pull/8654#discussion_r293644729
 
 

 ##########
 File path: 
flink-runtime/src/test/java/org/apache/flink/runtime/io/network/partition/ResultPartitionBuilder.java
 ##########
 @@ -112,13 +114,19 @@ public ResultPartitionBuilder setBufferPoolFactory(
                return this;
        }
 
+       public ResultPartitionBuilder isReleasedOnConsumption(boolean 
releasedOnConsumption) {
+               this.releasedOnConsumption = releasedOnConsumption;
+               return this;
+       }
+
        public ResultPartition build() {
                ResultPartitionFactory resultPartitionFactory = new 
ResultPartitionFactory(
                        partitionManager,
                        ioManager,
                        networkBufferPool,
                        networkBuffersPerChannel,
-                       floatingNetworkBuffersPerGate);
+                       floatingNetworkBuffersPerGate,
+                       true);
 
 Review comment:
   After this value is set true, it seems no way to generate `ResultPartition` 
atm via builder no matter with `releasedOnConsumption` is set true or false.
   Another option is make this value false, and let `releasedOnConsumption` 
default value is true, then the final tag could  also be changed via 
`ResultPartitionBuilder#isReleasedOnConsumption(false)`.
   I am not sure whether to adjust this issue atm or fix when required future.

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to