How to solve InaccessibleObjectException (“Unable to make {member} accessible: module {A} does not ‘opens {package}’ to {B}”) on Java 9?

The exception is caused by the Java Platform Module System that was introduced in Java 9, particularly its implementation of strong encapsulation. It only allows access under certain conditions, the most prominent ones are: the type has to be public the owning package has to be exported The same limitations are true for reflection, which … Read more

Replacements for deprecated JPMS modules with Java EE APIs

Instead of using the deprecated Java EE modules, use the following artifacts. JAF (java.activation) JavaBeans Activation Framework (now Jakarta Activation) is a standalone technology (available on Maven Central): <dependency> <groupId>com.sun.activation</groupId> <artifactId>jakarta.activation</artifactId> <version>1.2.2</version> </dependency> (Source) CORBA (java.corba) From JEP 320: There will not be a standalone version of CORBA unless third parties take over maintenance of … Read more