Access to internal APIs

The Java 9 platform has encapsulated internal APIs to increase security of the platform and applications written in Java. Applications that you program in Java 9 will not have default access to the JDK's internal APIs, unlike with previous versions of the Java platform. Oracle has identified some internal APIs as critical; those APIs remain accessible via the jdk.unsupported JDK module.

The aforementioned critical APIs (internal to the JDK) are:

  • sun.misc
  • sun.misc.Unsafe
  • sun.reflect.Reflection
  • sun.reflect.ReflectionFactory.newConstrutorForSerialization

If you have pre-Java 9 applications that implement any sun.* or com.sun.* package, you will likely run into problems migrating your applications to Java 9. In order ...

Get Java 9: Building Robust Modular Applications now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.