You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/02/05 10:56:48 UTC

[GitHub] [flink] StephanEwen commented on issue #11018: [FLINK-15905][runtime] Fix race condition between allocation and release of OpaqueMemoryResource

StephanEwen commented on issue #11018: [FLINK-15905][runtime] Fix race condition between allocation and release of OpaqueMemoryResource
URL: https://github.com/apache/flink/pull/11018#issuecomment-582352549
 
 
   The `finally` block should make sure that we don't corrupt the memory managers accounting.
   The exception handling for the resource itself is up to the caller.
   
   If the shared cache is not properly disposed (RocksDB swallows this in `closeQuietly()`) can in theory lead to the fact that native memory is not released and we have a leak.
   
   In practice, the RocksDB code throws no exceptions when problems occur, so we cannot react to that anyways.
   
   In any case, the change of logic would be required in the RocksDB code, not int the code of this PR.
   So far, the code's contract is "memory manager makes sure its part stays consistent" and the external resource user needs to decide what to do when that disposal fails.
   
   
   

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


With regards,
Apache Git Services