As of Java 17 --illegal-access
is effectively obsolete https://openjdk.java.net/jeps/403
Any use of this option, whether with permit, warn, debug, or deny, will have no effect other than to issue a warning message. We expect to remove the --illegal-access option entirely in a future release.
Because of this, using openjdk17 early access builds, I'm seeing an issue with jackson
https://github.com/FasterXML/jackson-databind/issues/3168. It seems to me that they're advocating --add-opens
usage and struggle to envisage a holistic "fix".
I'd like to avoid adding --add-opens
because if it's not jackson
, it's the next dependency. I don't want to have to change JVM args across environments because of dependency changes. How do I avoid this?