Why can I not download OpenJDK-17 in my IntelliJ? - java

I have a Spring Boot application and I'm trying to set the JDK to OpenJDK-17. I've downloaded it from Java, then I go to IDE and Project Settings > Project Structure > SDKs, and then I click on the '+' > Download JDK. Then when I set the version to 17, I don't see OpenJDK-17 anywhere...
I get the following options:
Amazon Corretto 17.0.6
Azul Zulu Community 17.0.6
BellSoft Liberica JDK 17.0.5
Eclipse Temurin (AdoptOpenJDK HotSpot) 17.0.5
GraalVM Community Edition 17
IBM Semeru (AdoptOpenJDK OpenJ9) 17.0.5
SAP SapMachine 17.0.5
---------Other Versions---------
Oracle OpenJDK 19.0.2

I don't know for sure the rational of the Intellij for (no longer?) including a link to a "vanilla" OpenJDK 17 download site. However my guess is that it is related to this notice on the https://jdk.java.net/17/ release page:
JDK 17 Releases
JDK 17 has been superseded. Please visit jdk.java.net for the current version.
Older releases, which do not include the most up to date security vulnerability fixes and are no longer recommended for use in production, remain available in the OpenJDK Archive.
Note that the OpenJDK team are no longer publishing new builds for OpenJDK 17. If you want the current Java 17 LTS build, you get it as an Oracle release or you get it from a 3rd-party vendor. These should all include the most recent security patches.
The Intellij team would be doing users a disservice if they provided an easy way for users to download an old and potentially insecure OpenJDK Java 17 build.

OpenJDK is basically a source only project (though they do release reference binaries for the first six months, which usually results in three releases, e.g. 17.0.0 - 17.0.2). After those three months, newer releases are only available through the vendors (e.g. for Java 17.0.5). All those listed are variants of OpenJDK 17 (except IBM Semeru, which is OpenJ9, which itself is a variant of OpenJDK). And bar vendor specific extras, or optional features like garbage collectors, they are basically the same, and have been tested for compliance with the Java specification.
In the Java world, you pick a vendor, and use its binaries instead of the binaries from OpenJDK itself (which generally don't go further then x.0.2, while vendor specific versions continue to receive updates if they are LTS versions). Personally, I usually use Eclipse Temurin builds.

Related

who is the distributor of openjdk docker image

my understanding is you need to have a distributor to use openjdk someone like (oracle openjdk, adoptopenjdk) but on docker repo for openjdk how do I find out who is the distributor if I just use their reference documentation
{the code below in copied from openjdk official docker repo}
FROM openjdk:11
COPY . /usr/src/myapp
WORKDIR /usr/src/myapp
RUN javac Main.java
CMD ["java", "Main"]
moving from java 8 to java 11
It's all written there on the docker page: https://hub.docker.com/_/openjdk/
openjdk:<version>
This is the defacto image. [...] These are the suite
code names for releases of Debian and indicate which release the image
is based on. [...]
openjdk:<version> (from 12 onwards), [...]
Starting with openjdk:12
the default image as well as the -oracle and -oraclelinux7 variants
are based on the official Oracle Linux 7 image which is provided under
the GPLv2 as per the Oracle Linux End User Agreement (EULA). [...]
TL;DR: the images are maintained by the Docker community, versions < 12 ship the OpenJDK build from Debian or Alpine Linux, later versions ship the Oracle builds.
By the way, until Version including 8, the Oracle JDK was more freely available. Anyway, Linux distributions built their own binaries. The binary distributions by AdoptOpenJDK, Amazon Corretto, etc. are only there, because Oracle doesn't provide binary builds freely anymore. But you can download OpenJDK and build it yourself, if you like.
Edit: You could also ssh into the image and run java -version
Edit2: Java 7 and support
I want to address your comment on my answer. You specifically asked for Java version 7. This version is quite old (first release in 2011!) and you will not find any long term support for without paying for commercial support. Period.
This version also predates the license changes to Oracle binaries, so the whole AdoptOpenJDK argument doesn't matter.
On the OpenJDK Docker Hub page, you can see different images shipping Java 7 builds, some with Alpine Linux and some with Debian Jessie. Those are - presumably, I've only verified that for Debian - builds of the open source OpenJDK project by that distribution. So the GPL with classpath exception should be the license that applies (read: you can use it commercially).
Note that even the LTS-support for Debian Jessie ends next month: https://wiki.debian.org/LTS
That shouldn't be necessarily a problem, depending on where you want to run that image (i.e., facing the public internet vs. private intranet).
If you have to stick with such an old version of Java, you have few options (maybe taking a modern linux image and build OpenJDK yourself [that will be painful, I imagine]).
Edit3: Recent version 7 support and v8+ from AdoptOpenJdk
OK, so you clarified in your comment, that you are not actually looking for version 7 builds.
I did, however, find an up-to-date and supported build of Java 7, by Azul: https://hub.docker.com/r/azul/zulu-openjdk
But you said you're running version 8, looking to go to 11. Then I would highly recommend AdoptOpenJDK, which is currently the most popular build. They offer Docker images as well (Note: they offer different JVMs: Hotspot is the default and highly recommended, OpenJ9 is based on a development by IBM)

Why is JRE 10 outdated and JRE 8 up-to-date?

I (as a non-Java kind of guy) am puzzled that my local JRE 10 installation required an update, but when updating, I get the JRE 8! This is even reported on https://java.com/en/download/more_info10.jsp:
Users who installed JRE 9 and/or JRE 10 (non Long-Term Support Releases) should remove those out-of-date versions of Java.
I would understand if JRE 11 would be the current version, but no, it's JRE 8:
If you still require Java on your computer download the latest release of JRE 8 available at java.com, which is the only currently supported major release of Java targeting desktop deployment.
How can this be?
The explanation is right there on that page you linked and quoted.
Relevant section highlighted.
"desktop deployment".
If you still require Java on your computer download the latest release
of JRE 8 available at java.com, which is the only currently supported
major release of Java targeting desktop deployment.
Short answer:
Java 9 and 10 are not a Long Term Support (LTS) release, and have expired.
Java 8 commercial supports end January 2019, public updates for personal use through December 2020 though.
Java 11 is the current and is also a LTS support release.
So todays choice is between java 8 and 11. But 11 removed applets and browser integration and other desktop technologies (JavaFX, java webstart etc). See list below and link to source. See also the Oracle white paper of 2018-03, Java Client Roadmap Update.
Further details:
Oracle has decided to stop releasing several variants of JRE on their own. As well as requiring a license for production use for newer releases. For example 32bit variants are no more, traditional desktop variants not available as there is no no java webstart and javafx is separated out since jdk 11+ etc, Oracle is more focusing on 64bit and server.
Put together with the fact that 9 and 10 are not Long term support releases (and they have expired) this leaves you with the choice of Java 8 for this particular use case for now.
JDK public updates for java 8 from oracle will end in January 2019 (and December 2020 for personal use) so at least until then is the current desktop java version of choice, from Oracle that is.
The current version of java 11, is only available as a 64bit JDK (development kit download) from oracle. No suitable desktop JRE (just the runtime).
Removed in JDK 11 release from Oracle:
Important Changes and Information
The following are some important changes in and information about this release. In some cases, additional details about the changes described below are provided in these Release Notes.
The deployment stack, required for Applets and Web Start Applications, was deprecated in JDK 9 and has been removed in JDK 11.
Without a deployment stack, the entire section of supported browsers has been removed from the list of supported configurations of
JDK 11.
Auto-update, which was available for JRE installations on Windows and macOS, is no longer available.
In Windows and macOS, installing the JDK in previous releases optionally installed a JRE. In JDK 11, this is no longer an option.
In this release, the JRE or Server JRE is no longer offered. Only the JDK is offered. Users can use jlink to create smaller custom
runtimes.
JavaFX is no longer included in the JDK. It is now available as a separate download from openjfx.io.
Source: https://www.oracle.com/technetwork/java/javase/11-relnote-issues-5012449.html
Simple: Oracle's own support roadmap lists Java 8 as having "premier" support until 2022.
Conversely, Java 9 and 10 have had their premier support lapse in March and September of 2018. Oracle's new update model ensures that non-LTS releases from Java 9 onwards are only officially supported until the new version of Java arrives.
"Current" is a bit of a strong word when it comes to Java; technically, the latest version of Java that should be used by end consumers is Java 11 (as of time of writing), since that is the current LTS. However, not all applications which use Java may be up-to-date, so it's safest to fall back to Java 8 until your application vendor informs you that it's safe to upgrade.
Perhaps that's because Java 11 deprecated modules which are present in Java 10 e.g. JAXB or Java FX. Latest Java 8 still has these modules so the software that worked on Java 10 can potentially work with Java 8.

Changes required to migrate from Oracle JDK to OpenJDK

We are planning to migrate our project from Oracle JDK to OpenJDK. I have some questions regarding the same.
After doing some analysis I found that OpenJDK will have a feature release every 6 months which is only supported until the next feature release.It's essentially a continuous stream of releases targeted to developers. Now my question is will it be a good idea to migrate to OpenJDK. Because if the
above statement is correct then we need to upgrade OpenJDK in our application every 6 months
Ref : Differences between Oracle JDK and OpenJDK
What are the basic changes required to do this migration. When I say basic changes, I mean I need to understand in very high level.One thing I know that is
Oracle JDK and Open JDK are having different jar licences. So do I need to replace all Oracle JDK jars with OpenJDK jars as its mentioned in
Migrating to OpenJDK from Oracle JDK ?
Currently we are using :
JDK 1.8
Tomcat 8
Windows Operating System for development. Services gets deployed in linux OS
Maven Build tool
Appreciate your help.
Thanks
Now my question is will it be a good idea to migrate to OpenJDK
For Java 11 you might want to, though by Java 11 they will be almost identical.
So do I need to replace all Oracle JDK jars with OpenJDK jars
I would install a version of OpenJDK and use the JARs which came with it. I wouldn't mix and match them.
JDK 1.8
I am not sure gain anything by migrating Java 8. Oracle Java 8 is still supported at least until Jan 2019. After that, you might not get any update, but you might not with OpenJDK either.
If your concern is getting support for Java 8, I suggest contacting a company which will give commercial support Java 8 such as Azul for what seemed like a reasonable price. https://www.azul.com/downloads/zulu/zulu-windows/

Why oracle is maintaining both openJDK and JDK? [duplicate]

NOTE: This question is from 2014. As of Java 11 OpenJDK and Oracle
JDK are converging.
Are there any crucial differences between Oracle and OpenJDK?
For example, are the garbage collection and other JVM parameters the same?
Does GC work differently between the two?
Both OpenJDK and Oracle JDK are created and maintained currently by Oracle only.
OpenJDK and Oracle JDK are implementations of the same Java specification passed the TCK (Java Technology Certification Kit).
Most of the vendors of JDK are written on top of OpenJDK by doing a few tweaks to [mostly to replace licensed proprietary parts / replace with more high-performance items that only work on specific OS] components without breaking the TCK compatibility.
Many vendors implemented the Java specification and got TCK passed. For example, IBM J9, Azul Zulu, Azul Zing, and Oracle JDK.
Almost every existing JDK is derived from OpenJDK.
As suggested by many, licensing is a change between JDKs.
Starting with JDK 11 accessing the long time support Oracle JDK/Java SE will now require a commercial license. You should now pay attention to which JDK you're installing as Oracle JDK without subscription could stop working. source
Ref: List of Java virtual machines
For Java 7, nothing crucial. The OpenJDK project is mostly based on HotSpot source code donated by Sun.
Moreover, OpenJDK was selected to be the reference implementation for Java 7 and is maintained by Oracle engineers.
There's a more detailed answer from 2012 on difference between JVM, JDK, JRE & OpenJDK, which links to an Oracle blog post:
Q: What is the difference between the source code found in the OpenJDK
repository, and the code you use to build the Oracle JDK?
A: It is very close - our build process for Oracle JDK releases builds
on OpenJDK 7 by adding just a couple of pieces, like the deployment code,
which includes Oracle's implementation of the Java Plugin and Java
WebStart, as well as some closed source third party components like a
graphics rasterizer, some open source third party components, like
Rhino, and a few bits and pieces here and there, like additional
documentation or third party fonts. Moving forward, our intent is to
open source all pieces of the Oracle JDK except those that we consider
commercial features such as JRockit Mission Control (not yet available
in Oracle JDK), and replace encumbered third party components with
open source alternatives to achieve closer parity between the code
bases.
A key difference going forward is the release schedule and support policy.
OpenJDK
OpenJDK will have a feature release every 6 months which is only supported until the next feature release. It's essentially a continuous stream of releases targeted to developers.
Oracle JDK
The Oracle JDK is targeted more towards an enterprise audience which values stability. It's based on one of the OpenJDK releases but
is then given long term support (LTS). The Oracle JDK has releases planned every 3 years.
Source: https://www.oracle.com/java/java9-screencasts.html?bcid=5582439790001&playerType=single-social&size=events
For Java 8, Oracle JDK vs. OpenJDK my take of key differences:
OpenJDK is an open source implementation of the Java Standard Edition platform with contribution from Oracle and the open Java community.
OpenJDK is released under license GPL v2 wherein Oracle JDK is licensed under Oracle Binary Code License Agreement.
Actually, Oracle JDK’s build process builds from OpenJDK source code. So there is no major technical difference between Oracle JDK and OpenJDK.
Apart from the base code, Oracle JDK includes, Oracle’s implementation of Java Plugin and Java WebStart. It also includes third-party closed source and open source components like graphics rasterizer and Rhino respectively.
OpenJDK Font Renderer and Oracle JDK Flight Recorder are the noticeable major differences between Oracle JDK and OpenJDK.
Rockit was the Oracle’s JVM and from Java SE 7, HotSpot and JRockit merged into a single JVM. So now we have only the merged HotSpot JVM available.
There are instances where people claim that they had issues while running OpenJDK and that got solved when switched over to Oracle JDK.
Twitter has its own JDK.
Software like Minecraft expects Oracle JDK to be used. In fact, warns.
For a full list of differences please see the source article: Oracle JDK vs OpenJDK and Java JDK Development Process
The Oracle and OpenJDK JVMs are the same and have the same GC features (as of the latest versions 10+). Prior to Oracle managing the OpenJDK JVM there were concrete differences that made that old Openjdk JVM almost unusable in many environments. The JVMs are now the same.
The JDKs which include the JVM as part of the Kit, differ by licensing, release and maintenance schedule, and the software libraries included in the JDK. Crucial differences to me also mean things that would make code not run if not present. Not only licensing.
diff --brief -r openjdk oraclejdk
Crucially the following files are missing in addition to a bunch of others on the linux JDK (So if you 'claimed' that code didn't work on OpenJDK and did so on OracleJDK while you were using javafx then you were correct):
Only in jdk-10.0.1/bin: javapackager
Only in jdk-10.0.1/bin: javaws
Only in jdk-10.0.1/bin: jcontrol
Only in jdk-10.0.1/bin: jmc
Only in jdk-10.0.1/bin: jweblauncher
Only in jdk-10.0.1/lib: ant-javafx.jar
Only in jdk-10.0.1/lib: deploy
Only in jdk-10.0.1/lib: deploy.jar
Only in jdk-10.0.1/lib: desktop
Only in jdk-10.0.1/lib: fontconfig.bfc
Only in jdk-10.0.1/lib: fontconfig.properties.src
Only in jdk-10.0.1/lib: fontconfig.RedHat.6.bfc
Only in jdk-10.0.1/lib: fontconfig.RedHat.6.properties.src
Only in jdk-10.0.1/lib: fontconfig.SuSE.11.bfc
Only in jdk-10.0.1/lib: fontconfig.SuSE.11.properties.src
Only in jdk-10.0.1/lib: fonts
Only in jdk-10.0.1/lib: javafx.properties
Only in jdk-10.0.1/lib: javafx-swt.jar
Only in jdk-10.0.1/lib: java.jnlp.jar
Only in jdk-10.0.1/lib: javaws.jar
Only in jdk-10.0.1/lib: jdk.deploy.jar
Only in jdk-10.0.1/lib: jdk.javaws.jar
Only in jdk-10.0.1/lib: jdk.plugin.jar
Only in jdk-10.0.1/lib: jfr
Only in jdk-10.0.1/lib: libavplugin-53.so
Only in jdk-10.0.1/lib: libavplugin-54.so
Only in jdk-10.0.1/lib: libavplugin-55.so
Only in jdk-10.0.1/lib: libavplugin-56.so
Only in jdk-10.0.1/lib: libavplugin-57.so
Only in jdk-10.0.1/lib: libavplugin-ffmpeg-56.so
Only in jdk-10.0.1/lib: libavplugin-ffmpeg-57.so
Only in jdk-10.0.1/lib: libbci.so
Only in jdk-10.0.1/lib: libcmm.so
Only in jdk-10.0.1/lib: libdecora_sse.so
Only in jdk-10.0.1/lib: libdeploy.so
Only in jdk-10.0.1/lib: libfxplugins.so
Only in jdk-10.0.1/lib: libglassgtk2.so
Only in jdk-10.0.1/lib: libglassgtk3.so
Only in jdk-10.0.1/lib: libglass.so
Only in jdk-10.0.1/lib: libgstreamer-lite.so
Only in jdk-10.0.1/lib: libjavafx_font_freetype.so
Only in jdk-10.0.1/lib: libjavafx_font_pango.so
Only in jdk-10.0.1/lib: libjavafx_font.so
Only in jdk-10.0.1/lib: libjavafx_iio.so
Only in jdk-10.0.1/lib: libjfxmedia.so
Only in jdk-10.0.1/lib: libjfxwebkit.so
Only in jdk-10.0.1/lib: libnpjp2.so
Only in jdk-10.0.1/lib: libprism_common.so
Only in jdk-10.0.1/lib: libprism_es2.so
Only in jdk-10.0.1/lib: libprism_sw.so
Only in jdk-10.0.1/lib: librm.so
Only in jdk-10.0.1/lib: libt2k.so
Only in jdk-10.0.1/lib: locale
Only in jdk-10.0.1/lib: missioncontrol
Only in jdk-10.0.1/lib: oblique-fonts
Only in jdk-10.0.1/lib: plugin.jar
Only in jdk-10.0.1/lib: plugin-legacy.jar
Only in jdk-10.0.1/lib/security: blacklist
Only in jdk-10.0.1/lib/security: public_suffix_list.dat
Only in jdk-10.0.1/lib/security: trusted.libraries
Only in openjdk-10.0.1: man`
According to the oracle blog, Oracle JDK Releases for Java 11 and Later
Starting with Java 11, Oracle will provide JDK releases under the open source GNU General Public License v2, with the Classpath Exception (GPLv2+CPE), and under a commercial license for those using the Oracle JDK as part of an Oracle product or service, or who do not wish to use open source software. This combination of using an open source license and a commercial license replaces the historical “BCL” license, which had a combination of free and paid commercial terms.
Different builds will be provided for each license, but these builds are functionally identical aside from some cosmetic and packaging differences, described in detail below.
From the BCL to the GPL
The Binary Code License for Oracle Java SE technologies (“BCL”) has been the primary license for Oracle Java SE technologies for well over a decade. The BCL permits use without license fees under certain conditions. To simplify things going forward, Oracle started providing open source licensed OpenJDK builds as of Java 9, using the same license model as the Linux platform. If you are used to getting Oracle Java SE binaries for free, you can simply continue doing so with Oracle’s OpenJDK builds available at jdk.java.net. If you are used to getting Oracle Java SE binaries as part of a commercial product or service from Oracle, then you can continue to get Oracle JDK releases through My Oracle Support (MOS), and other locations.
Functionally identical and interchangeable...
Oracle’s BCL-licensed JDK historically contained “commercial features” that were not available in OpenJDK builds. As promised, however, over the past year Oracle has contributed these features to the OpenJDK Community, including:
Java Flight Recorder,
Java Mission Control,
Application Class-Data Sharing, and
ZGC.
From Java 11 forward, therefore, Oracle JDK builds and OpenJDK builds will be essentially identical.
...yet with some cosmetic and packaging differences
There do remain a small number of differences, some intentional and cosmetic, and some simply because more time to discuss with OpenJDK contributors is warranted.
Oracle JDK 11 emits a warning when using the -XX:+UnlockCommercialFeatures option, whereas in OpenJDK builds this option results in an error. This option was never part of OpenJDK and it would not make sense to add it now, since there are no commercial features in OpenJDK. This difference remains in order to make it easier for users of Oracle JDK 10 and earlier releases to migrate to Oracle JDK 11 and later.
Oracle JDK 11 can be configured to provide usage log data to the “Advanced Management Console” tool, which is a separate commercial Oracle product. We will work with other OpenJDK contributors to discuss how such usage data may be useful in OpenJDK in future releases, if at all. This difference remains primarily to provide a consistent experience to Oracle customers until such decisions are made.
The javac --release command behaves differently for the Java 9 and Java 10 targets, since in those releases the Oracle JDK contained some additional modules that were not part of corresponding OpenJDK releases:
javafx.base
javafx.controls
javafx.fxml
javafx.graphics
javafx.media
javafx.web
java.jnlp
jdk.jfr
jdk.management.cmm
jdk.management.jfr
jdk.management.resource
jdk.packager.services
jdk.snmp
This difference remains in order to provide a consistent experience for specific kinds of legacy use. These modules are either now available separately as part of OpenJFX, are now in both OpenJDK and the Oracle JDK because they were commercial features which Oracle contributed to OpenJDK (e.g., Flight Recorder), or were removed from Oracle JDK 11 (e.g., JNLP).
The output of the java --version and java -fullversion commands will distinguish Oracle JDK builds from OpenJDK builds, so that support teams can diagnose any issues that may exist. Specifically, running java --version with an Oracle JDK 11 build results in:
java 11 2018-09-25
Java(TM) SE Runtime Environment 18.9 (build 11+28)
Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11+28, mixed mode)
And for an OpenJDK 11 build:
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)
The Oracle JDK has always required third party cryptographic providers to be signed by a known certificate. The cryptography framework in OpenJDK has an open cryptographic interface, meaning it does not restrict which providers can be used. Oracle JDK 11 will continue to require a valid signature, and Oracle OpenJDK builds will continue to allow the use of either a valid signature or unsigned third party crypto provider.
Oracle JDK 11 will continue to include installers, branding and JRE packaging for an experience consistent with legacy desktop uses. Oracle OpenJDK builds are currently available as zip and tar.gz files, while alternative distribution formats are being considered.
Oracle will deliver releases every three years, while OpenJDK will be released every six months.
Oracle provides long term support for its releases. On the other
hand, OpenJDK supports the changes to a release only until the next
version is released.
Oracle JDK was licensed under Oracle Binary Code License Agreement,
whereas OpenJDK has the GNU General Public License (GNU GPL) version
2 with a linking exception.
Oracle product has Flight Recorder, Java Mission Control, and
Application Class-Data Sharing features, while OpenJDK has the Font
Renderer feature.Also, Oracle has more Garbage Collection options
and better renderers,
Oracle JDK is fully developed by Oracle Corporation whereas the
OpenJDK is developed by Oracle, OpenJDK, and the Java Community.
However, the top-notch companies like Red Hat, Azul Systems, IBM,
Apple Inc., SAP AG also take an active part in its development.
From Java 11 turn to a big change
Oracle will change its historical “BCL” license with a combination of an open source and commercial license
Oracle’s kit for Java 11 emits a warning when using the -XX:+UnlockCommercialFeatures option, whereas in OpenJDK builds, this option results in an error
Oracle JDK offers a configuration to provide usage log data to the “Advanced Management Console” tool
Oracle has always required third party cryptographic providers to be signed by a known certificate, while cryptography framework in OpenJDK has an open cryptographic interface, which means there is no restriction as to which providers can be used
Oracle JDK 11 will continue to include installers, branding, and JRE packaging, whereas OpenJDK builds are currently available as zip and tar.gz files
The javac –release command behaves differently for the Java 9 and Java 10 targets due to the presence of some additional modules in Oracle’s release
The output of the java –version and java -fullversion commands will distinguish Oracle’s builds from OpenJDK builds
Update : 25-Aug-2019
for more details oracle-vs-openjdk
A list of the few remaining cosmetic and packaging differences between Oracle JDK 11 and OpenJDK 11 can be found in this blog post:
https://blogs.oracle.com/java-platform-group/oracle-jdk-releases-for-java-11-and-later
In short:
Oracle JDK 11 emits a warning when using the -XX:+UnlockCommercialFeatures option,
it can be configured to provide usage log data to the “Advanced Management Console” tool,
it has always required third party cryptographic providers to be signed by a known certificate,
it will continue to include installers, branding and JRE packaging,
while the javac --release command behaves slightly differently for the Java 9 and Java 10 targets, and
the output of the java --version and java -fullversion commands will distinguish Oracle JDK builds from OpenJDK builds.
Aside from the obvious licensing difference, the major difference between OpenJDK and OracleJDK 11 are stability and performance updates.
Source: https://www.youtube.com/watch?v=Adv9--6IcQI&t=385
Every 6 months the two codebases will be in-sync. But during the 6 month window OpenJDK will only receive security updates while OracleJDK will receive additional stability and performance updates.
Given that update releases only occur every 3 months for both OpenJDK and OracleJDK this means that you are missing out on (at most) 3 months worth of fixes until the next major release comes out and you upgrade. However, if you choose to stick to LTS releases then a commercial license begins to make more sense.
Also for Java 8 an interesting performance benchmark for reactive (non-blocking) Spring Boot REST application being hosted on various JVMs by AMIS Technology Blog has been published in Nov 2018 showing that, among other differences:
OpenJDK has higher CPU usage than OracleJDK,
OpenJDK has slightly lower response time than OracleJDK,
OpenJDK has higher memory usage than OracleJDK,
For details please see the source article.
Of course YMMV, this is just one of the benchmarks.
OpenJDK
OpenJDK is opened source code, it is maintained and developed by Oracle, but allows communities and other companies to participate in this development, such as Red Hat, Azul Systems, IBM, Apple Inc, etc. OpenJDK is both a JDK product and a specification, any company or organization that wants to use OpenJDK to create a new variant must comply with those specifications.
OpenJDK is developed by Oracle and the community contributions. We sometimes have issues on its stability; however, based on user feedback, it will be upgraded to perform better. OpenJDK is regularly updated, around every 6 months.
Oracle JDK
Oracle JDK is maintained and developed by Oracle. It complies with OpenJDK specifications, but it is not opened source code. Oracle JDK is much better in terms of the JVM responsiveness and productivity. It focuses more on the stability due to its importance to the corporate customers.
Source: https://o7planning.org/12571/history-of-java-and-the-difference-between-oracle-jdk-and-openjdk
My understanding is that Oracle JDK can't be used in production, therefore I cannot legally use it (without paying), for the web application I am building for my company. I have to use OpenJDK. Please correct me if I am wrong! From this article.
Starting with Java 11, the Oracle JDK is restricted to development and
testing environments. Oracle JDKs may only be used in production if
you buy the commercial support. Instead, Oracle will provide Java
builds based on OpenJDK for free which can be used in production. But
for the official Oracle JDK the real roadmap will look like this:
UPDATE: I'm wrong. I can use Oracle JDK for free but won't get security updates after 6 mos and we'll have to assume the risk. Look at the above linked article section "What does the new release train mean to my company?".
It is very close - our build process for Oracle JDK releases builds on OpenJDK 7 by adding just a couple of pieces, like the deployment code, which includes Oracle's implementation of the Java Plugin and Java WebStart, as well as some closed source third-party components like a graphics rasterizer, some open-source third party components, like Rhino, and a few bits and pieces here and there, like additional documentation or third-party fonts. Moving forward, we intend to open source all pieces of the Oracle JDK except those that we consider commercial features such as JRockit Mission Control (not yet available in Oracle JDK) and replace encumbered third-party components with open source alternatives to achieve closer parity between the codebases.
· Yes, the garbage collection and other JVM parameters are the same.
· The performance of GC is the same in both.

Are Open JDK and JDK7 the same thing?

Are Open JDK and JDK7 the same thing?
Open JDK is a free (but not certified) implementation of the JLS (java language specification) where JDK7 is the next version of Sun's JDK which is currently 1.6 (or just Java 6 as the marketing devision of Sun called it).
OpenJDK was initially based only on the JDK 7.0 version of the Java platform.
Since February 15, 2008, there are two separate OpenJDK projects:
The main OpenJDK project, which is based on the JDK 7.0 version of the Java platform
The JDK 6 project, which provides an Open-source version of Java 6.0.
I hope this clears the confusion a bit.
It appears to be a Solaris<-->OpenSolaris situation, viz. there's an open-source project with as much code as possible; the fixes get transferred back to the main software, which the vendor supports and sells. OpenJDK is a project. OpenJDK version 7 and JDK7 appear to be largely but not exactly the same (per here).

Categories

Resources