Differences between Oracle JDK and OpenJDK

The current differences are:

  1. Only Oracle JDK offers Solaris, only OpenJDK offers Alpine Linux.
  2. Oracle JDK offers "installers" (MSI, rpm, deb, etc.) which not only place the JDK binaries in your system but also contain update rules and in some cases handle some common configurations like set common environmental variables (such as, JAVA_HOME in Windows) and establish file associations (such as, use java to launch .jar files). OpenJDK is offered only as a compressed archive (tar.gz or .zip).
  3. javac —release for release values 9 and 10 behave differently. Oracle JDK binaries include APIs that were not added to OpenJDK binaries like JavaFX, resource management, and (pre-JDK 11 changes) JFR APIs.
  4. Oracle JDK offers "JDK" and "JRE". OpenJDK offers only "JDK".
  5. Usage Logging is only available in Oracle JDK.
  6. OpenJDK will (continue to) throw a mistake and halt if the -XX:+UnlockCommercialFeatures flag is employed. Oracle JDK not requires the flag and can print a warning but continue execution if used.
  7. Oracle JDK requires that third party cryptographic providers be signed with an Oracle-provided certificate. OpenJDK will continue allowing the use of unsigned third-party crypto providers.
  8. The output of the java -version will be different. Oracle JDK will say java and include LTS. OpenJDK (when produced by Oracle) will say OpenJDK and not include the Oracle-specific LTS identifier.
  9. Oracle JDK will be released under the OTN License. Any License file will be got to point to OTN. OpenJDK is going to be released under GPLv2wCP and can include the GPL license.
  10. Oracle JDK will distribute FreeType under the FreeType license and OpenJDK will do so under GPLv2. The contents of \legal\java.desktop\freetype.md will therefore be different.
  11. Oracle JDK has Java cup and steam icons and OpenJDK has Duke icons.
  12. Oracle JDK source code includes "ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms." and OpenJDK source includes the GPL.

Leave a comment now