An Update On Java for IBM i
September 23, 2020 Alex Woodie
Java is alive and well on IBM i, but it’s in a state of change at the moment, thanks to changes Oracle made to how it licenses and develops the popular technology. Meanwhile, IBM is getting ready to exploit upcoming Power10 capabilities with its server runtime for Java.
In late June, IBM quietly released an early access version of Java 11 through its RPM process. The release, which IBM i shops can access via yum or through ACS, is not production ready, and is only intended for testing purposes.
“We have, however, done thorough functional testing of various workloads, including Apache Camel, ActiveMQ, Tomcat, maven, Jenkins, etc.,” IBM’s open source architect for IBM i Jesse Gorzinski states on the bitbucket site. “We are releasing an ‘early access’ version to solicit feedback from the IBM i community, and we welcome your feedback for any testing you do!”
The fact that IBM is moving forward with a Java 11 environment is good news for the IBM i community. IBM first committed to supporting Java 11 back in 2018, when Java 11 was first unveiled as a long-term release (LTR). As a fully supported LTR, Java 11 was intended to replace Java 8 (the previously released LTR) and tie Java users over until the next major LTR release of Java, Java 17, is unveiled in late 2021.
However, concerns over the Java 11 environment and the likelihood that it would break existing applications, has pushed the development of the OpenJDK Java 11 package for IBM i and the Java community as a whole, leaving users to rely on Java 8, which will be supported by Oracle (and organizations that it licenses Java to) through 2025, at least. But IBM has been working through those compatibility issues and appears close to delivering the new OpenJDK Java 11 package for IBM i.
As IBM i shops get closer to the first new release of server-side Java since 2015, they’re also being forced to contend with just a bit of drama on the client side of things. That’s because, early last year, Oracle decided that it would begin charging businesses for using Java client updates released after January 2019.
This change in licensing doesn’t impact Java on the IBM i server, since IBM takes care of licensing the technology on IBM i. But the change does impact Java on the client, and that’s critical for Access Client Solutions (ACS), which has become the main client tool for interacting with the IBM i server. ACS, of course, is written in Java and requires a JVM to run on.
For IBM i shops who did not (and do not) want to pay Oracle for support for Java running on desktops and laptops, IBM recommends using either the OpenJ9 JVM from AdoptOpenJDK or the Hotspot distribution from the OpenJDK organization. IBM said that it works with both of these organizations
IBM also offers two paid Java runtime options, which are based on the OpenJ9 JVM. These offerings are sold under the “IBM Runtimes for Business” banner, and are identified by product numbers 5737-F61 and 5737-J49. Customers that want the latest, greatest Java runtime should opt for the J49 option, which adds monitoring, according to this column from Steve Will, the chief architect for IBM i.
Java 8 remains, by far, the most popular version of Java across the industry, according to a 2018 survey of the Java community by Jetbrains. Concerns over applications breaking under changes made with Java 9 (which is not coming to the IBM i platform, but which will be reflected in Java 11), as well as the client-side license changes that went into effect in early 2019, are the key drivers for keeping users from moving to Java 11, it said.
Meanwhile, the open source development of Java continues. According to Julian Wang, IBM’s Java architect for Power, the open source Java community remains committed to improving the language and runtime.
“Nowadays, the collaboration on Java and JDK improvement are all happening in the OpenJDK community,” Wang said last week during his POWERUp 2020 presentation on the Java ecosystem and IBM i. “Every major JDK vendor and JDK builder is in this community. There is active collaboration to maintain a healthy ecosystem of Java in this community.”
In his presentation for COMMON, Wang explained how he and his team are working to overcome challenges in Java execution and to take advantage of new capabilities. To eliminate performance slowdowns caused by the just in time (JIT) compiler, Wang explained how a JIT server running outside the JVM (in the cloud) can bolster performance.
“What the JIT server is going to do is take out the JIT compiler from JVM and run the JIT compiler in the cloud as a service, so each JVM can request the JIT compilation service from the JIT server,” he said. “In this way, from a JVM resource capacity planning perspective, you can truly go after your applications’ characteristics–how much memory it’s going to consume, how much the CPU is going to consume–and disregard the JIT compiler side of consuming resources.”
Pre-compiling of Java programs, or static compiling, is also making a comeback in the Java community as a way to get around the JIT compiler’s use of resources, Wang said. He mentioned a new OpenJDK initiative called Project Leyden that’s seeking to create a standard static compilation method across Java implementations.
There are tradeoffs to be considered, and the Java community has not decided which way to go. “What is the best end game? It could be some kind of hybrid approach,” Wang said. “Watch out for developments in this space.”
Meanwhile, Wang and his team are working on supporting the upcoming Power10 processor with the OpenJ9 JVM. When systems with Power10 processors ship in late 2021 (probably early 2022 for IBM i shops), it will bring substantial benefits to IBM i customers running Java applications, he said.
Specifically, Wang and his team are seeking to support Power10 instruction set architecture (ISA) elements like PC relative addressing, the load store with length for arrayCopy, and new setb for branchless code generation.
The team will also be looking to take advantage of the NX GZIP accelerator, which will be useful for compressing and decompressing JAR and ZIP files. “That is taking advantage of the new library on AIX,” he said. “Hopefully IBM i can provide that support as well. Once it’s available, we can do the same.”
Security and cryptography is a focus with Power10, and the Power Java team is looking to make improvements there too. Wang said the OpenJ9 JDKs for Linux and AIX have already taken advantage of the new Java Cryptography engine, which will accelerate encryption routines by a few times to up to 100x.
“In OpenJ9, we are going to take advantage and exploit Power10’s new ISA and the features,” he said. “We have a single runtime for across different JDK releases, so we only need to this once, and that . . . is going to be available in Java 8, Java 11, and Java 17.”
RELATED ITEMS
Java License Fallout Continues Impacting IBM i Shops
IBM Clarifies Java Options Following Oracle License Crackdown
IBM i Slated to Support Java 11
Java On IBM i: A Developing Situation