zhijiangW opened a new pull request #9262: [FLINK-13442][network] Remove 
unnecessary notifySubpartitionConsumed method from view reader
URL: https://github.com/apache/flink/pull/9262
 
 
   ## What is the purpose of the change
   
   *Currently the methods of 
`NetworkSequenceViewReader#notifySubpartitionConsumed` and 
`NetworkSequenceViewReader#releaseAllResources` would be called meanwhile in 
netty stack during releasing resources.*
   
   *As confirmed in FLINK-13245, in order to make this release logic simple and 
clean, we could remove the redundant `notifySubpartitionConsumed` from 
`NetworkSequenceViewReader` side, and also remove it from 
`ResultSubpartitionView` side. In the implementation of 
`ResultSubpartitionView#releaseAllResources` it would further notify the parent 
subpartition of consumed state via 
`ResultSubpartition#notifySubpartitionConsumed` which further feedback to 
parent `ResultPartition` layer via `onConsumedSubpartition`. Finally 
`ResultPartition` could decide whether to release itself or not.*
   
   *E.g. for the case of `ReleaseOnConsumptionResultPartition` which is mainly 
used for pipelined partition, it would release partition after reference 
counter decreased to
   0. For the case of `ResultPartition` which would be generated for blocking 
partition by default, it would never be released after notifying consumed. And 
the JM/scheduler
   would decide when to release partition properly. In addition, 
`InputChannel#notifySubpartitionConsumed` could also be removed as a result of 
above.*
   
   ## Brief change log
   
     - *Remove `notifySubpartitionConsumed` from `NetworkSequenceViewReader`*
     - *Remove `notifySubpartitionConsumed` from `ResultSubpartitionView`*
     - *Remove `notifySubpartitionConsumed` from `InputChannel`*
   
   ## Verifying this change
   
   This change is a trivial rework / code cleanup without any test coverage.
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API, i.e., is any changed class annotated with 
`@Public(Evolving)`: (no)
     - The serializers: (no)
     - The runtime per-record code paths (performance sensitive): (no)
     - Anything that affects deployment or recovery: JobManager (and its 
components), Checkpointing, Yarn/Mesos, ZooKeeper: (no)
     - The S3 file system connector: (no)
   
   ## Documentation
   
     - Does this pull request introduce a new feature? (no)
     - If yes, how is the feature documented? (not applicable)
   

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to