7 About Compact Profiles
This chapter discusses the concept of compact profiles in the Oracle Java SE Embedded platform.
This chapter contains the following sections:
Compact Profiles for Subsets of the Java SE API
You can minimize space requirements on the embedded device by limiting the static footprint to Java API packages that the application uses. You can build a custom JRE that contains the full set of Java SE APIs or one of three subsets, called profiles.
Compact1 Profile APIs
Compact2 Profile APIs
Adds these packages to compact1:
Remote Method Invocation (RMI, JSR 66))
Java API for XML Processing (JAXP, JSR 280)
Java Database Connectivity (JDBC, JSR 169)
When configured withe the minimal JVM, the compact2 profile APIs have a static footprint of about 17MB.
Compact3 Profile APIs
The compact2 profile adds serviceability, naming, the compiler API, and more security.
For a description of serviceability, see
Note that the compact3 profiles cannot be configured with the minimal JVM.
Full JRE APIs
The full JRE adds desktop, web services, and CORBA APIs. It also supports Java Flight Recorder (JFR) command line options.
The full JRE APIs include all the Java SE classes, yet space-saving optimizations make a full Oracle Java SE Embedded JRE substantially smaller than a Java SE JRE. When configured with the client JVM, the full JRE APIs have a static footprint of about 50MB.
For headless configurations, the full JRE APIs include the
java.swing classes. These classes are provided for printing and drawing bitmaps in memory. An attempt to create a GUI window in this mode raises the
Configuring the JRE for Swing/AWT Headful Applications describes a configuration that supports AWT/Swing.
Determining Compact Profiles for API Objects
The Java SE API documentation shows which compact profiles each API object belongs to. For example, Figure 7-1 is a screenshot of an API documentation page showing that the
javax.sql package belongs to all three compact profiles.
Figure 7-1 Example Javadoc with Information about Compact Profiles
Description of "Figure 7-1 Example Javadoc with Information about Compact Profiles"