Skip to content

BIRT 4.12 JDK 11 vs. JDK 17 - Solution of new module handling (javax, com.sun.net.*, etc.) #1160

Answered by hvbtup
speckyspooky asked this question in Q&A
Discussion options

You must be logged in to vote

I don't have a solution, but this could be related to a similar issue I noticed with Java 17 (see #1138).

In my case, the exception was
java.lang.IllegalAccessException: class org.mozilla.javascript.MemberBox cannot access class sun.java2d.SunGraphics2D (in module java.desktop) because module java.desktop does not export sun.java2d to unnamed module

In fact the mentioned class still exists in the JDK, but it could not be accessed from Rhino due to the complexities of interfaces and abstract classes.

In my case, one possible workaround (which I didn't follow further because it failed a few code lines later) was to move the code that deals with this class directly into a custom JAR in such …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@speckyspooky
Comment options

speckyspooky Dec 30, 2022
Collaborator Author

Answer selected by speckyspooky
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants