Three significant events have happened recently in Java and Java development
This is the first note for InApp’s clients and its developers to understand the key reasons for the need to move to JDK 11 and our recommended procedure for moving to Java 11 and beyond.
The main reason to move on to Java 11 is the stoppage of support for Java 8 JDK and the consequent non-availability of patches and security fixes to the JDK and Java 8 libraries. The other reasons include the new features of the language and the Development Kit, which makes it useful to move.
For some time at least we can stick to JDK if we are supported by non-oracle vendors like IBM WebSphere and RedHat’s JBoss as these vendors will release the security fixes. Another option is to use the Open Source JDK supported by communities including the Oracle Supported OpenJDK. This will remain free with community support.
This may be the option most people will take. Moving to JDK 11 is not difficult as most of the JDK 8 programs will run directly on JDK 11. There are tools available to run through your source code and check the same. We recommend that we move to JDK 11 with the existing code and probably minor variations. Then in the next phase try and take advantage of the new features of JDK 11.
Oracle is using a licensing system for charging users for Java 11 and later editions. Their rates are available at:
NOTE: It may be please noted that this is NOT a universal document for all cases of Java usage. Each particular instance or project and implementation is unique in itself and have to be handled with care to its environment and priorities. This document is a high-level document to make clients and our own Java team aware of the changes and InApp’s generic approach.
Java originated under the leadership of James Gosling by Sun Microsystems in 1995. The first version came out in Jan 1996. Its success came from its becoming a web programming language. The concepts of JSP, JDBC, and others made it suitable for Enterprise Applications on the web. Java has been a prime product from Sun Microsystems until it was taken over by Oracle and it is now maintained by Oracle Corporation.
There were two popular streams of Java the Standard Edition and the Enterprise Edition. They have a very mixed history and for more information, please look up the Wikipedia Pages on Java and J2EE
The Enterprise Edition was a popular edition and has been used in many applications and application frameworks like IBM’s Websphere, Oracle’s Weblogic, RedHat’s JBoss, Apache’s Tomcat, and many more.
Java EE was maintained by Oracle under the Java Community Process. On September 12, 2017, Oracle Corporation announced that it would submit Java EE to the Eclipse Foundation. The Eclipse Foundation was forced to change the name of Java EE because Oracle owns the trademark for the name “Java.” On February 26, 2018, it was announced that the new name of Java EE will be Jakarta EE.
InApp’s advice will be to completely move out of J2EE and consider reengineering the application to Java SE or other programming environments like PHP, Python for the backend, and HTML5 Javascript for the front end.
Java Standard Edition has emerged as the popular edition post-2010 and Oracle continues to maintain and develop it. Currently, it is on Version 12.
| Java Standard Edition Release Dt. | Support Till | Major New Features |
| Java 8 | ||
| March 2014 (LTS**) | Commercial Users January 2019 Personal Users: End 2020 | Lambda expressions, Method references, Functional interfaces, Stream API, Default methods |
| Java 9 | ||
| September 2017 (Non LTS) | March 2018 | Platform Module System (Project Jigsaw)Interface Private MethodsTry-With ResourcesAnonymous Classes |
| Java 10 | ||
| March 2018(Non LTS) | September 2018 | Application Data-Class SharingParallel Full GC for G1Local-variable type inference |
| Java 11 | ||
| September 2018(Paid LTS) | July 2019 | Run Java File with single command removed the Java EE and CORBA ModulesReactive HTTP/2 ClientEpsilon GC |
** LTS Versions are “major versions” where Oracle support is for a longer term.
For more information, please refer here
Oracle has moved from big bang major releases often at an interval of 3 years or more to more streamlined fixed “feature releases”,
There will not be any beta versions. All Java releases will be major releases that contain only features that are ready to be used.
The new cadence makes it more manageable and predictable for third-party tools vendors, as there will be a steady stream of smaller updates.
As of Java 11, Oracle now maintains two different JDK builds:
All Java/JDK development is done in the public OpenJDK repository and then they are propagated to the Oracle JDK. Hence, Oracle JDK builds and OpenJDK builds will be essentially identical but with some cosmetic and packaging differences (mainly in the license and support model).
Since Java 11, as Oracle’s commercial JDK and Oracle’s OpenJDK builds are functionally the same, we should be able to run our applications on either without having to make any changes or losing any features.
The code on Java SE 8 will run on Java SE 11 without any changes. Hence there is no immediate need for reengineering. However, it is highly recommended to step into Java 11 platform as it has many features and makes the system easier to use.
Oracle JDK 8 is undergoing the “End of Public Updates” process, and there will be no more free updates for commercial use after January 2019.
Staying with Oracle’s Java SE 8 has the following implications:
Companies can either go onto a paid support plan or use a Java SE 8 / OpenJDK 8 binary distribution from another provider or continue to use Oracle JDK 8 indefinitely without updates.
If you are not using Oracle JDK 8, then your current Java SE 8 / OpenJDK 8 provider will provide updates and/or paid support plans to choose from.
Some options available include:
Java 11 did not have any major language changes but has taken the advantage of features released in the earlier versions including Java 8, 9, and 10. Java 8 code will run under Java 11, 12, and further, as they will be backward compatible. However, it will be very useful to take advantage of the enhancements provided by Java 11.
Some of the core enhancements include:
Containerizing applications in Docker makes it easy to abstract key application elements from the infrastructure and thus makes it easier to scale services with changing demand.
The JVM now recognizes constraints set by container control groups. Both memory and CPU constraints can be used to manage Java applications directly in containers, these include:
The Java Platform module system introduces a new kind of Java programming component, the module, which is named, a self-describing collection of code and data. Now we can pack a customized subset of JRE, based on the individual needs of the applications that run on it, and increase their efficiency manifold with a drastically reduced footprint and increased performance.
The new API makes a clean break from the past, by abandoning any attempt to maintain protocol independence. Instead, the API focuses solely on HTTP.
The major incremental steps for migration are:
First of all download and install the latest JDK release. The application (jars) created with earlier Java versions can run on JDK 11 without major issues, Some exceptions are:
If your application starts successfully, look carefully at your tests and ensure that the behavior is the same as on the JDK version you have been using. For example, a few early adopters have noticed that their dates and currencies are formatted differently.
To ensure that the code works on the latest JDK release, understand the new features and changes in each JDK release.
Everything needs to be updated, including the IDE, the build tool, its plugins, and, most importantly, the dependencies. Some dependencies that we need to monitor (and versions that are known to work on Java 11):
Here are the recommended minimum versions for a few tools:
Compiling your code with the latest JDK compiler will ease migration to future releases since the code may depend on APIs and features, which have been identified as problematic.
Run the jdeps tool on your application to see what packages and classes your applications and libraries depend on. If you use internal APIs, then jdeps may suggest replacements to help you to update your code.
Once the application is working on JDK 11, some suggestions that can help you get the most from the Java SE Platform: