Short Version
In NetBeans under Project Properties → Sources → Source Binary Format, there is supposed to be an option to select a Java Profile:
But for me it's missing:
What's doing?
Long Version
Java has the option to run four modes:
- Compact 1
- Compact 2
- Compact 3
- Full JRE
The default has always been a "Full JRE" - there was nothing else. But they wanted to define more compact versions of the runtime. If you advertise you are willing to run with a more stripped-down version of the Java Runtime, it can give you faster application startup with, with less disk and memory usage.
It just comes at the cost of being able to use less of the JRE:
Full JRE | Compact1 | Compact2 | Compact3 | Full JRE |
---|---|---|---|---|
java.lang | ✔️ | ✔️ | ✔️ | ✔️ |
java.io | ✔️ | ✔️ | ✔️ | ✔️ |
java.nio | ✔️ | ✔️ | ✔️ | ✔️ |
java.text | ✔️ | ✔️ | ✔️ | ✔️ |
java.math | ✔️ | ✔️ | ✔️ | ✔️ |
java.net | ✔️ | ✔️ | ✔️ | ✔️ |
javax.net | ✔️ | ✔️ | ✔️ | ✔️ |
java.util | ✔️ | ✔️ | ✔️ | ✔️ |
java.util.logging | ✔️ | ✔️ | ✔️ | ✔️ |
java.security | ✔️ | ✔️ | ✔️ | ✔️ |
javax.crypto | ✔️ | ✔️ | ✔️ | ✔️ |
javax.security | ✔️ | ✔️ | ✔️ | ✔️ |
java.sql | ✔️ | ✔️ | ✔️ | |
javax.sql | ✔️ | ✔️ | ✔️ | |
javax.xml | ✔️ | ✔️ | ✔️ | |
org.w3c.dom | ✔️ | ✔️ | ✔️ | |
org.xml.sax | ✔️ | ✔️ | ✔️ | |
java.rmi | ✔️ | ✔️ | ✔️ | |
javax.rmi | ✔️ | ✔️ | ✔️ | |
javax.transaction | ✔️ | ✔️ | ✔️ | |
java.lang.management | ✔️ | ✔️ | ||
javax.management | ✔️ | ✔️ | ||
javax.naming | ✔️ | ✔️ | ||
javax.sql.rowset | ✔️ | ✔️ | ||
javax.security.auth.kerberos | ✔️ | ✔️ | ||
org.ietf.jgss | ✔️ | ✔️ | ||
javax.script | ✔️ | ✔️ | ||
javax.xml.crypto | ✔️ | ✔️ | ||
java.util.prefs | ✔️ | ✔️ | ||
javax.security.sasl | ✔️ | ✔️ | ||
javax.security.acl | ✔️ | ✔️ | ||
java.lang.instrument | ✔️ | ✔️ | ||
javax.annotation.processing | ✔️ | ✔️ | ||
javax.lang.model | ✔️ | ✔️ | ||
javax.lang.model.element | ✔️ | ✔️ | ||
javax.lang.model.type | ✔️ | ✔️ | ||
javax.lang.model.util | ✔️ | ✔️ | ||
javax.tools | ✔️ | ✔️ | ||
corba | ✔️ | |||
awt | ✔️ | |||
swing | ✔️ |
NetBeans IDE has the option to configure your Java Profile.
Their Overview of JDK 8 Support in NetBeans IDE page has the best explanation on the different profiles, and why they exist. But it also documents how to configure it in the IDE.
And for me it just isn't there.
Maybe there is some obscure option that must be enabled in the web.xml
, or some other project or configuration file.