With Oracle stopping free updates for Java 8 and effectively only maintaining free updates with the latest Java release (12 at the time of writing) a natural question arises… Which JDK should I use? This is a short article providing answers, depending on your circumstances.
Let’s look at different scenarios that you may be facing:
You are using Java 8 and want to keep Long Term Support (LTS) for free
In this case, you should use Amazon Correto OpenJDK 8 distribution. Amazon Correto is a free JDK distribution that will provide you with free long term support:
Long-term support (LTS) for Corretto includes performance enhancements and security updates for Corretto 8 until at least June 2023 at no cost.
Alternatively, Azul provides another JDK 8 distribution called Zulu. This also comes with LTS. It is worth checking to see, as they also provide support plans if you may wish to transfer from free to paid Java…
It is worth knowing that OpenJDK is also an option and there are projects keeping it up to date.
You want to use the latest LTS version of Java (11 currently) for free
Once again, I recommend going with Amazon Correto or alternatively Azul Zulu.
You are using Java and want pay for Long Term Support (LTS)
If for some reason you want to pay for support, you have two popular options: Oracle or Azul. If you are willing to pay for your Java you will be better off doing some additional research making sure that the support terms suit you. This is beyond the scope of this article.
It is worth noting that Azul Zulu also provides LTS support for versions that are not under LTS from Oracle.
You are Azure or AWS consumer already
For those that are already Amazon or Microsoft Cloud consumers, there is additional support provided for respectively Correto and Azulu Zulu.
If you have AWS Support Plan, “you can reach out for assistance with Corretto through your plan.” This is clarified in Corretto FAQ.
If you are developing Java software on Azure, you can use Azul Zulu Enterprise for free. Quote from the release:
“Java developers on Microsoft Azure and Azure Stack can build and run production Java applications using Azul Systems Zulu Enterprise builds of OpenJDK without incurring additional support costs”
You want to use the latest Java available
In this case, you can freely choose between Oracle, OpenJDK and Azul Zulu. All these latest versions are free, but if you go with Oracle or OpenJDK you may need to keep upgrading to the new Java versions to keep receiving security patches.
Summary
You don’t need to pay to use any version of Java, as there are plenty of supported distributions available. Make sure that you are using the right one and keep coding!
What ist about AdoptOpenJDK?
AdoptOpenJDK is about providing OpenJDK binaries on different systems rather than providing LTS for any particular distribution. You should look into AdoptOpenJDK if you need to find OpenJDK binaries for your specific platform. It is a great project anyway.
What about Bellsoft’s Liberica https://bell-sw.com/ or RedHat’s OpenJDK https://developers.redhat.com/products/openjdk/overview ?
What is your rationale for Corretto over Azul or Oracle’s OpenJDK? You seem to mention all three, but there isn’t much discussion about why you’d choose one over another? Are there technical, security, marketplace health, corporate responsibility, or political considerations you’ve weighed to arrive at this recommendation?
I was not aware of Bellsoft’s Liberica so thanks for adding it here. Not sure what free LTS support is Red Hat providing. If they do, they could be added.
Correto promises free LTS, while OpenJDK does not. Azul is a viable choice and preferred if you are on Azure.
Beyond that, the goal of this article is to provide a simple solution to a problem that I was asked about numerous times- what do we do, once the Oracle JDK falls out of LTS. One could write another, much more elaborated article comparing pros and cons of every single JDK distribution out there, but this was beyond the scope.
Thanks for commenting with two additional alternatives! If this decision is critical for some (not for everyone it is), then you have added two additional viable choices. Liberica looks especially interesting!