azagrebin opened a new pull request #9997: [FLINK-14522] Introduce 
JavaGcCleanerWrapper to find Java GC Cleaner depending on JVM version
URL: https://github.com/apache/flink/pull/9997
 
 
   ## What is the purpose of the change
   
   sun.misc.Cleaner is not available since Java 9.
   
   It was moved to jdk.internal.ref.Cleaner of java.base module (Open 
JDK-8148117), but another new public API  was introduced to achieve the same 
behaviour (java.lang.ref.Cleaner);
   
   A popular solution is use reflection to look up for the location of the 
Cleaner class depending on running JVM version.
   
   ## Brief change log
   
     - Introduce JavaGcCleanerWrapper which uses reflection to look up and 
provide proper Cleaner implementation depending on JVM version on runtime
     - Introduce JavaGcCleanerWrapperTest to test that the clean method is 
called 
   
   ## Verifying this change
   
   Run JavaGcCleanerWrapperTest
   
   ## 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