OpenJDK - ready for production? [closed] - java

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 6 years ago.
Improve this question
Wondering if anyone switched from Sun/Oracle JDK to OpenJDK?
Is it production ready? Is the version 7 release any different from the Oracle version?

The answer to the question of whether OpenJDK is production-ready likely depends on your application workload. At Azul Systems, we launched the Zulu product around OpenJDK with the intention of supporting production workloads with OpenJDK.
To do this, we prepare our own binary distributions of OpenJDK, test them against the Technology Compatibility Kit ("TCK") for the relevant Java SE standard (ie. 6, 7, and 8) on Windows and Linux platforms, then exercise them in various application scenarios: Java EE application servers, GUI apps, benchmarks, virtualization and cloud contexts, debuggers, etc.
So far OpenJDK is standing up to many types of workloads. There remain a handful of differences between OpenJDK and Hotspot that may or may not pertain to your own workload and application design, for example the browser JRE plugin and Java Web Start are in Hotspot but not in OpenJDK. The core JVM in OpenJDK remains very similar: same interpreter, same C1 and C2 compilers, same garbage collectors, same source compiler and class API hierarchy, and similar basic tools. Many of the remaining gaps stem from encumbrances, meaning items present in the Oracle JDK that could not be made open from their original inclusion and license impact.
In response to the "is Java 7 ready", the differences were indeed likely most pronounced in OpenJDK 6, given its source code evolution through the IcedTea open source project. OpenJDK 7 and OpenJDK 8 started off at GA very similar, then grow to have differences throughout the maintenance cycle, where security fixes flow into OpenJDK regularly, along with big batches of fixes when Oracle does their quarterly critical patch updates. Plus, backports of worthy source changes and fixes into 6 and 7 from the 8 and 9 repositories happen continually throughout the lifecycle. Good code is good code.
When considering production operations, you may also want to consider tech support for the JVM and JDK. While Zulu itself is free, if your production environment warrants support, Azul offers fee-based tech support through different tiers of the Zulu Enterprise offering.
Zulu and Zulu Enterprise are described on the Azul website here:
http://www.azulsystems.com/products/zulu
Disclaimer: I am the Product Manager for Zulu and Zing products at Azul Systems.

There are still regressions in OpenJDK that might affect your operations. See for example : Memory error when trying to change Apache Tomcat port from 8080 to 80
OpenJDK can't be considered as a safe drop in replacement for Sun Java yet, test carefully your applications.
EDIT: For clarity, the issue mentioned is caused by a slightly increased memory usage of OpenJDK compared to Sun Java (not much, but sufficiently to create a memory issue in this case).

In our production environment we develop some JavaEE applications, I changed JDK to OpenJDK, everything worked pretty well.

I have been using java-1.8.0-openjdk as part of CentOS 7 stack in all cases of needing a jvm. I have been using it with various setups of Elasticsearch, Hadoop, and also as the foundation for Eclipse (Luna). I have not seen any issues after months of use with these applications in the lab. It has performed flawlessly as far as I can tell.

Related

Options to use Java free for commercial use [duplicate]

This question already has answers here:
Which free version of Java can I use for production environments and or commercial purposes?
(5 answers)
Closed 8 months ago.
If I want to keep my software (be it an application or even a game for Windows) free for me as developer/publisher as well as my users/clients what should I do (use)/can I even do that today?
To download the JDK you have two options (that I know of): OpenJDK / jdk.java.net and Oracle JDK. Am I right to assume that you can use everything from OpenJDK free of charge for commercial use as well, while Oracle JDK depends how they stand, some are free while for some you need a subscription (JDK 17/18 says that they are free under NFTC while for JDK 8 you need a subscription)?
As for JRE, can I download Java from here (version: Windows Offline (64-bit)) and add it in a folder with the software, to check if the user/client has it or not, and prompt an install it they don't have it?
To download the JDK you have two options (that I know of)
Oh, heck no. There's Temurin by Adoptium, Zulu by Azul Systems, Coretto by Amazon. Other vendors include Red Hat, IBM, SAP, BellSoft, Microsoft, Oracle, Pivotal, etc.
Am I right to assume that you can use everything from OpenJDK free of charge for commercial use as well
Yes. But note that they stop supporting it when a new version comes out. I'd use Adoptium or Coretto instead.

Migrating to OpenJDK from Oracle JDK

I am working on migrating my java application from Oracle JDK to adoptOpenJdk.So what changes would be required to migrate to AdoptOpenJdk.
Feature parity
Oracle has committed to keeping their Oracle JDK product at feature parity with the codebase in the OpenJDK project. So any Java app running on Oracle JDK should run on any other platform built faithfully from the OpenJDK codebase. You need not make any changes to your Java programming.
Be aware that OpenJDK only provides source code. For binaries and installers, you must look elsewhere. Several companies provide such binaries and installers. One of those is a joint venture known as AdoptOpenJDK. Others include Azul Systems, Red Hat/IBM, SAP, BellSoft, Amazon, Oracle, and Pivotal.
Most of the vendors, including Oracle, provide JVMs using the HotSpot optimizing compiler and runtime. AdoptOpenJDK (at least) offers you a choice to obtain a build using the OpenJ9 optimizing runtime instead. Your Java app should run well on either HotSpot or OpenJ9, but you may see a different performance profile.
See my Answer to a similar Question.
Be aware that the current licensing terms for the Oracle JDK product require that for use in production you must pay a fee. That product is free-of-cost only for non-production use such as development and testing. If you do not want to pay such a fee to Oracle, use their unsupported product at JDK.java.net, or use a JVM provided by one of the other vendors as shown in this flowchart.

How to decide on jdk version - Oracle's shorter release cycle [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 3 years ago.
Improve this question
I am getting confused by the new short release cycle paradigma of Oracle. Here is a table with support dates:
Java 8 has a bigger support window than most of the following Jdk. Java 9 is supposed to be End of support now, same for java 10.
It becomes a non trivial task deciding on a jdk version.
Oracle introduces the therm of Long therm support release. What does this mean for the Non-LTS versions ? Are they similar to the minor releases ?
In the past, Java major releases often tended to be loaded with far-reaching features that had a massive impact on the code that you could and should write, like generics (Java 5), functional constructs (Java 8), and modules (Java 9). Such releases took a long time, and often involved delays for various reasons.
Presumably drawing a lesson from this, Oracle decided to overhaul the development style for Java to be more incremental or "agile", if you like. Instead of having feature-loaded major releases that can sometimes take many years to finish, they want to publish major releases with fewer new features, each in a fixed release schedule every six months.
Java 10 was the first version under this new release model, and Java 9 already got deprecated with the release of Java 10. Java 11, which was released in September 2018 is a Long Term Support (LTS) release with support until 2026 (Source). This is very similar to what many are used to from the Ubuntu release model (On a side note, they even planned to replace the version numbers with something involving the year and month of release or so, similar to what Canonical is doing with Ubuntu, but dropped that idea for some reason).
Using a non-LTS version of Java now implies a commitment to update your software that uses the JDK every 6 month. It shouldn't be as involved as migrating code from one major Java version to another in the past because, as described, the language changes are supposed to happen in a more incremental way, but it's definitely something to consider. If you don't want to make this commitment, you should stick to the LTS versions, which means to stick with Java 8 or Java 11.
For a new "greenfield" project, Java 11 is most probably the best choice by now. But it might be necessary to stick with Java 8 if the toolchain to be used does not fully support Java 11 yet.
I hope this will help.
If you can upgrade to the latest JDK every six month, pick the latest version. Otherwise pick the LTS version; if the next LTS is going to be released soon (before your release date), then you might want to use the latest version and switch to the LTS before your release.
Also, Oracle JDK is now (since 11) fully based on the OpenJDK project, so any OpenJDK build from your favorite vendor might be just as good a choice for you as Oracle JDK -- or even better.

Azul OpenJDK vs Oraclejdk [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 years ago.
Improve this question
why do people use Azul’s Zulu 9.0.0.15 release of OpenJDK instead of JDK downloaded from oracle.com? I came across this OpenJDK in the Effective java book and haven't tried this open jdk before. Is this because Oracle made the JDK commercial?
why do people use Azul’s Zulu 9.0.0.15 release of OpenJDK instead of JDK downloaded from oracle.com?
In short, there is no version of Java 9 freely supported by Oracle. You can download the last free version from Oracle.
From March 2019, Oracle will only give free support for Java 12 (for 6 months). Oracle will provide free support for the latest version for the first 6 months of release.
However, there are other organisations, like Azul, which provide commercially supported releases from Java 8. To get Oracle's supported releases you need to pay a subscription.
Other organisations such as AdoptJDK and RedHat have their own releases.
For more information
https://www.oracle.com/technetwork/java/javase/tech/eol-135779.html
Is this because Oracle made the JDK commercial?
The OpenJDK has been around since Java 6, but there were some differences and not a strong reason for many to shift versions.
From Java 11, the main difference between OpenJDK and Oracle Java 11 is the installer.
Hopefully, we will see more companies paying for support for the products they rely on to help make money, but also see a variety of options for free use in a secure way.
There are a few OpenJDK's out there.
The official Open JDK and Oracle's JDK are based on the same code but have different licensing models.
The main reason for creating them was to tweak some parts of the code to better handle a part of the API that you think should work differently.
For example, let's say you are a company that uses JAVA and notices that some part of the API works to slowly for your needs. You then can try to improve it and submit it to be part of the Oracle OpenJDK. But it could be rejected or the time it takes for it to be approved takes too long. You might opt to just branch the OpenJDK to make your own version.
At the moment Oracle is going to stop giving its own implementation of the JDK for free but it its version of OpenJDK will remain open and free.
If you read here you will see that Zulu too is just OpenJDK certified and promised to be maintained.
My guess is that the company is just using OpenJDK to give better service to its subscribers so they will get notified when new fixes and patches become available to the general public.
I don't think they change anything in the JDK but just create custom delivery tools around it.
There will be no free LTS release from Oracle as of JDK 11 and that JDK 8 public updates (for commercial users) end in Jan 2019; we are seeing a lot of interest in Zulu.
Here is what is Oracle have announced.
There are now two binaries available from Oracle: the traditional
Oracle JDK (java.oracle.com) which is provided under the Oracle Binary
Code License (with field-of-use restrictions). There is also now an
OpenJDK binary (jdk.java.net) released under the GPLv2 with CPE
license.
As of JDK 11, the Oracle JDK will still be available for download and can be used in development and testing for free. If you want to deploy it into production, you will need a commercial support contract with Oracle. The OpenJDK binaries are free, but every release (including those Oracle designate LTS) will only have updates available for six months (until the next JDK release).
https://youtu.be/YauqubC8FKM?t=1281

What is the reason to use OpenJDK?

I somehow understand the differences between Oracle JDK and Open JDK.
But I can't find reasons to use Open JDK.
Because Oracle JDK already has everything one would need and sometimes faster than Open JDK.
In which cases should someone use Open JDK?
Is it just for legality issues?
If yes, then what are issues?
That because I have been still develop all my projects using Oracle JDK
Other Answers are correct. Here is some other information as well, including vital changes as of early 2021.
Source-code versus Binaries/installers
understand the differences between Oracle JDK and Open JDK.
To sum it up: source-code versus binaries/installers.
OpenJDK is an open-source project, implementing the Java Specifications, JSRs, and JEPs that define the Java platform. This project publishes only source-code, not binaries or installers to get Java running on your computer (except for some early-access builds). Oracle is the principal participant in the OpenJDK project, alongside IBM & Red Hat, Apple, SAP, Azul Systems, Microsoft, and others.
Many companies provide distributions of OpenJDK for installation, as binaries or installers. Oracle is one such company.
Oracle actually provides two such products:
Oracle JDKA commercial product, with paid support plans. (Free-of-cost only for development & testing, not deployment. Read their terms.)
jdk.java.netA build of the OpenJDK source-code, freely available, unsupported.
Oracle has declared their intention to keep their commercial product Oracle JDK at feature-parity with OpenJDK. Oracle even went so far as to open-source and make available at no cost their formerly commercial tools Mission Control and Flight Recorder, both now a part of OpenJDK. So there is nearly no practical difference. One significant difference is that the Oracle company reserves the right to rapidly supply their paid support customer base with urgent patches not currently found in OpenJDK. Ditto for other vendors selling support.
[And for the record, Oracle offers a third implementation of Java, GraalVM, which is a very specialized product.]
Here is a flowchart graphic I made to help guide you in selecting a provider of a Java implementation.
And here is a list of motivations you might consider in choosing a distribution.
November 2017: At the time this question was asked, the reasons for choosing between OpenJDK and Oracle JDK include:
Availability of builds / installers for specific platforms. For example, last time I checked there were no Oracle JDK distros in ".deb" format for Debian / Ubuntu. And no OpenJDK builds for Windows.
Oracle JDK has some commercial features that can be enabled by people who have paid. They are not present on OpenJDK.
Oracle JDK has an annoying click-through license. This is a pain if you are trying to automate deployment; e.g. to cloud VMs. By contrast, OpenJDK on Linux (at least) can be installed and updated using the platform's package manager.
There may be issues if you wanted commercial support for OpenJDK.
There were no substantive license differences between Oracle JDK and OpenJDK if you just plan to use the software. (There are some constraints on binary redistribution for Oracle JDK, but they are about shipping non-standard or stripped-down versions of the Java platform.)
In the future, some of these differences will go away, according to this blog page:
Faster and Easier Use and Redistribution of Java SE
Update in December 2018:
As of January 2019, Oracle JDK Java 8 will be EOL for commercial uses. (But free support will continue until January 2020 for personal use.)
1
Java 9 and Java 10 are EOL.
Commercial uses of Oracle JDK Java 11 and later require a support contract or a subscription from Oracle. OpenJDK Java builds do not have this requirement.
Oracle do not provide support for OpenJDK Java builds, but support is available from 3rd parties. Third parties will also port Oracle security fixes to OpenJDK builds.
Further reading:
Java Is Still Free
OpenJDK Life Cycle and Support Policy (RedHat)
The future of Java and OpenJDK updates without Oracle support
What has changed in Java Release and Update Availability? (Azul Systems)
AdoptOpenJDK Support
1
EOL stands for end-of-life.
An end-of-life (EOL) product is a product that does not receive continuing support, either because existing marketing, support and other processes are terminated, or it is at the end of its useful life.
OpenJDK comes tightly integrated with the distribution update process. For example, on Fedora, this means that you simply can run
dnf update
without activating third-party repositories, and you will get the latest OpenJDK version with all relevant fixes.
OpenJDK is tested by the distribution vendor on this particular distribution. Oracle has different reference platforms for testing of OpenJDK. In the case of Fedora, software written in Java is tested with the OpenJDK version provided by the distribution, while the combination of that software with Oracle JDK receives much less testing.
Oracle also bundles their Java downloads with additional software such as browser toolbars, performance measurement and monitoring tools.
For those, who read this in 2019.
Java SE 8 is the last Java SE release targeting Desktop deployment (eg, Java Web Start and a stand-alone system JRE). Java SE 8 will be end of public updates in January 2019, after which commercial users need to either transition to other technologies, or purchase a Java SE Subscription.
So, another reason to use OpenJDK (in addition to what Stephen C said): it's free of charge for all purposes.

Categories