Oracle Java SE Embedded: Developer's Guide

5 About Custom JREs

Learn about the basic concepts that underlie the custom JREs that you create with Oracle Java SE Embedded technology.

This page contains the following topics:

Your Choices When Creating a Custom JRE

Space optimizations make a full JRE created with Oracle Java SE Embedded smaller than the functionally equivalent out-of-the-box Java SE JRE.

In addition, you can create even smaller JREs in steps down to about 12 MB of static footprint. Using the jrecreate command, you can choose among components to build a custom JRE that matches expected workloads and response goals.

Figure 5-1 shows the components that go into a custom JRE, and how JREs of varying function and size can be created from the Oracle Java SE Embedded components.

Figure 5-1 jrecreate Composes Custom JREs from Components

Description of Figure 5-1 follows
Description of "Figure 5-1 jrecreate Composes Custom JREs from Components "

You can find out more about the Oracle Java SE Embedded JRE components shown on the left in Figure 5-1 by following these links:

The right side of Figure 5-1 shows examples of custom JREs, created with the jrecreate tool included with Oracle Java SE Embedded. In this diagram, the simplest JRE consists of a minimal JVM and the compact1 profile APIs. More complex is a client JVM, compact2 profile APIs, and basic graphics. Largest and most capable is a server JVM, full JRE APIs, graphics with controls, and a cryptographic token interface.

Cryptographic Service Providers

For cryptographic operations, the Java language defines standard APIs for application developers, which are implemented by replaceable service providers.

Oracle Java SE Embedded includes two optional provider packages. Choose either or both, as your application requires. See Create Your JRE with jrecreate for how to use the jrecreate tool to add provider packages. The packages are:


By default, the jrecreate command creates the US English (en_us) locale. Optionally, it creates all Java SE locales. For information about Java SE locales, see the list of supported locales for JRE. To add optional locales to your JRE, see the --extension option in jrecreate Options.

Character Encodings

By default, the jrecreate command creates the basic set of character encodings. Optionally, it creates the extended set defined at the same URL. To add optional character encodings, see the --extension option in jrecreate Options.

Nashorn JavaScript Engine

All Oracle Java SE profiles and the full JRE include the javax.scripting API which supports scripting language statements in Java source files. At run time, the scripting statements are executed by a user-supplied scripting engine.

To include the Nashorn JavaScript engine in a JRE, see the --extension option in jrecreate Options.

For more information on the Nashorn JavaScript engine, see

JSR 197 Specification JAR

JSR 197 is the specification of the Generic Connection Framework (GCF) Optional Package for the Java 2 Platform, Standard Edition, version 1.0. The API is equivalent to CLDC 1.0 GCF. The MIDP 2.0 and FP 1.1 have a more complete GCF API (for example HTTPS).

The embedded package supports:

  • file

    Local file read, write, and read/write

  • datagram

    UDP send and receive

  • socket

    TCP client and server

  • http

    HTTP client

Note that the JSR 197 JAR provided with Oracle Java SE Embedded has no functional implementation. It delegates all functions to the and packages.

The JSR 197 specification APIs are provided as a JAR file in the Oracle Java SE Embedded download bundle. It is not supported by the jrecreate command, but you can add it manually. The JAR file is located in the following directory of an Oracle Java SE Embedded installation:


This location needs to be in the classpath for any application that needs it, or you can add it as a standard extension into the lib/ext directory of the JRE.

Close Window

Table of Contents

Oracle Java SE Embedded: Developer's Guide

Expand | Collapse