[ https://issues.apache.org/jira/browse/SPARK-24421?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16679897#comment-16679897 ]
Sean Owen commented on SPARK-24421: ----------------------------------- Using reflection to set the Cleaner works. We also have to use reflection to call Cleaner.clean() in StorageUtils. However this causes an IllegalAccessException, not because it's private, but because the methods are of course not exported from the java.base module. This can be disabled with command line flags but that's not a great solution. I'll look at workarounds but ideas welcome! Good news is that this appears to be the only change needed to get compilation to work, and tests are running pretty well other than this so far. > sun.misc.Unsafe in JDK9+ > ------------------------ > > Key: SPARK-24421 > URL: https://issues.apache.org/jira/browse/SPARK-24421 > Project: Spark > Issue Type: Sub-task > Components: Build > Affects Versions: 2.3.0 > Reporter: DB Tsai > Priority: Major > > Many internal APIs such as unsafe are encapsulated in JDK9+, see > http://openjdk.java.net/jeps/260 for detail. > To use Unsafe, we need to add *jdk.unsupported* to our code’s module > declaration: > {code:java} > module java9unsafe { > requires jdk.unsupported; > } > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org