Public Repository

Last pushed: 7 hours ago
Short Description
Docker Images for Eclipse OpenJ9 Version 10 binaries built by AdoptOpenJDK.
Full Description

Supported tags and respective Dockerfile links


Quick reference


The images in this repository contain OpenJDK binaries that are built with Eclipse OpenJ9.

Eclipse OpenJ9 is a high performance, scalable, Java™ virtual machine (JVM) implementation that has a proven track record of running Java applications in production environments. Contributed to the Eclipse project by IBM, the OpenJ9 JVM underpins the IBM SDK, Java Technology Edition product that is a core component of many IBM Enterprise software products. Continued development of OpenJ9 at the Eclipse foundation ensures wider collaboration, fresh innovation, and the opportunity to influence the development of OpenJ9 for the next generation of Java applications.

OpenJDK binaries that include Eclipse OpenJ9 are available through AdoptOpenJDK.

Java and all Java-based trademarks and logos are trademarks or registered trademarks of Oracle and/or its affiliates.

Are the builds TCK Certified ?

This page has more information on which images are TCK certified.

Multi-arch image

OpenJ9 has multi-arch support so the same commands work on all supported architectures.

How to use this Image

To run a pre-built jar file with the latest Java 10 OpenJDK image, use the following commands:

FROM adoptopenjdk/openjdk10-openj9:nightly
RUN mkdir /opt/app
COPY japp.jar /opt/app
CMD ["java", "-jar", "/opt/app/japp.jar"]

You can build and run the Docker image as shown in the following example:

$ docker build -t japp .
$ docker run -it --rm japp

To get a specific version of a docker image, add the build number as shown in the following example:

$ docker run --rm -it adoptopenjdk/openjdk10-openj9:jdk- java -version
openjdk version "10.0.1" 2018-04-17
OpenJDK Runtime Environment (build 10.0.1+10)
Eclipse OpenJ9 VM (build openj9-0.9.0-rc1, JRE 10 Linux amd64-64-Bit Compressed References 20180628_85 (JIT enabled, AOT enabled)
OpenJ9   - da56ab5e
OMR      - da0c7eeb
JCL      - 73b1d6004c based on jdk-10.0.1+10)

Using the Class Data Sharing feature

Eclipse OpenJ9 provides a feature called Class data sharing. This mechanism offers transparent and dynamic sharing of data between multiple Java virtual machines (JVMs) running on the same host, which reduces the amount of physical memory consumed by each JVM instance. By providing partially verified classes and possibly pre-loaded classes in memory, this mechanism also improves the start up time of the JVM.

To enable class data sharing between JVMs that are running in different containers on the same host, a common location must be shared between containers. This requirement can be satisfied through the host or a data volume container. When enabled, class data sharing creates a named "class cache", which is a memory-mapped file, at the common location. This feature is enabled by passing the -Xshareclasses option to the JVM as shown in the following Dockerfile example:

FROM adoptopenjdk/openjdk10-openj9:nightly
RUN mkdir /opt/shareclasses
RUN mkdir /opt/app
COPY japp.jar /opt/app
CMD ["java", "-Xshareclasses:cacheDir=/opt/shareclasses", "-jar", "/opt/app/japp.jar"]

The cacheDir sub-option specifies the location of the class cache. For example /opt/sharedclasses. When sharing through the host, a host path must be mounted onto the container at the location the JVM expects to find the class cache. For example:

docker build -t japp .
docker run -it -v /path/on/host/shareclasses/dir:/opt/shareclasses japp

When sharing through a data volume container, create a named data volume container that shares a volume. For example:

docker create -v /opt/shareclasses --name classcache japp /bin/true

Then, start your JVM container by using the --volumes-from flag to mount the shared volume, as shown in the following example:

docker run -it --volumes-from classcache japp


The Dockerfiles and associated scripts are licensed under the Apache License, Version 2.0.

Licenses for the products installed within the images:

As with all Docker images, other software is likely to be included, which might be under other licenses (such as Bash, etc from the base distribution, along with any direct or indirect dependencies of the primary software being contained).

As for any pre-built image usage, it is the image user's responsibility to ensure that any use of this image complies with any relevant licenses for all software contained within.

Docker Pull Command