Differences between SapMachine and OpenJDK

RealCLanger edited this page Oct 22, 2018 · 4 revisions

It is the goal of the SapMachine team to keep SapMachine as close to OpenJDK as possible. Therefore features identified as required by SAP applications should be developed in and contributed to OpenJDK. Only if this is, for what ever reason, not possible, differences between SapMachine and OpenJDK are considered acceptable. However, they have to be kept as small as possible.

Features not accepted via the OpenJDK reviewing process may still find their way into OpenJDK code when switched off by default. It is generally considered acceptable to switch on such features by default in SapMachine.

Features which require functional changes in the code may still be acceptable. However, this will have to be decided for each particular case.

Version numbers

You can easily identify SapMachine from the output of the java -version command (see below). Although the version information of SapMacine and OpenJDK/OracleJDK are slightly different, the SapMachine version output still fully conforms to the format specified in the JEP 322: Time-Based Release Versioning and JEP 223: New Version-String Scheme.

SapMachine version information
$ ./sapmachine-11/bin/java -version
openjdk version "11" 2018-09-25 LTS
OpenJDK Runtime Environment (build 11+28-LTS-sapmachine-1)
OpenJDK 64-Bit Server VM (build 11+28-LTS-sapmachine-1, mixed mode)

In addition to the original OpenJDK version output (see below), SapMachine adds an optional part (i.e. LTS-sapmachine-1) to the version number. This optional part (defined as optional build information in JEP 322) start with LTS for long term support releases followed by the name sapmachine and ends with a SapMachine specific build number. So 11+28-LTS-sapmachine-1 actually means that the corresponding version is derived from the upstream OpenJDK version 11+28 plus some additional SapMachine specific changes (i.e. SapMachine build 1 based on OpenJDK build 11+28). In the case we’re doing a SapMachine specific fix to this version, the SapMachine specific build number will be increased and look as follows 11+28-LTS-sapmachine-2. Once we pull and merge with upstream, the SapMachine specific build number will be reset to zero (e.g. 11+29-LTS-sapmachine-0).

OpenJDK version information
$ ./jdk-11-openjdk/bin/java -version
openjdk version "11" 2018-09-25
OpenJDK Runtime Environment 18.9 (build 11+28)
OpenJDK 64-Bit Server VM 18.9 (build 11+28, mixed mode)

System properties

The following listing shows the differences in the Java system properties between SapMachine and OpenJDK. Besides the version differences already discussed above that’s mostly the different values for the various vendor properties:

-    java.runtime.version = 11+28
+    java.runtime.version = 11+28-LTS-sapmachine-1
-    java.vendor = Oracle Corporation
-    java.vendor.url = http://java.oracle.com/
-    java.vendor.url.bug = http://bugreport.java.com/bugreport/
-    java.vendor.version = 18.9
+    java.vendor = SAP SE
+    java.vendor.url = https://sapmachine.io
+    java.vendor.url.bug = https://github.com/SAP/SapMachine/issues/new
-    java.vm.vendor = Oracle Corporation
-    java.vm.version = 11+28
+    java.vm.vendor = SAP SE
+    java.vm.version = 11+28-LTS-sapmachine-1

Other minor differences

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.