Java Release Dates, Features, Latest Java Version, Latest Java LTS, Which Java Version Should Use

This page contains all the frequently asked questions on Java versions, releases, and features. The latest version of Java is Java 20 or JDK 20 released on March, 21st 2023

1. What is the latest version of Java? 

As of March 2023, the most recent Java version is Java 20.

2. When will be the Java 21 release?

Java 21 is scheduled for release on September 19, 2023.

3. Which is the latest Long term support Java version?

The current long-term support version (LTS) of Java is Java 17, released in September 2021.

4. What Java version should I use? 

The choice of Java version generally depends on the requirements of your specific project and the environments where your application will run. Here are a few factors to consider: 

Long-Term Support (LTS) Version: 

If stability and long-term support are crucial, you should stick with an LTS version, such as Java 11 or Java 17. These versions are supported by Oracle (and many others in the community) for many years and are best for production applications. 

Latest Version:

If you want to leverage the latest features, improvements, and bug fixes, then the newest version, such as Java 20 (as of March 2023), would be the choice. However, note that each version has a six-month lifespan before it's superseded by the next release, and they might not have commercial support.

Requirements of your project: 

Certain libraries or frameworks that your project depends on might require a specific minimum Java version. 

Compatibility: 

You also need to consider backward compatibility. Some new versions of Java deprecate features or make changes that are not backward compatible. 

Performance: 

Newer versions often have performance improvements over older versions, but it's always a good idea to test this in your own environment. 

In a nutshell, for commercial or production use, LTS versions are commonly chosen due to their extended support and stability, whereas for personal projects or learning, the latest version might be a good choice to stay up-to-date with Java's latest features and improvements. Always be sure to test the chosen Java version thoroughly in your environment before rolling it out.

5. Why some companies are still using Java 8?

There are several reasons why many companies are still using Java 8, despite newer versions being available: 

Long-Term Support (LTS): 

Java 8 was the last version to have "permanent" support from Oracle, while later versions have only six months before the next version is released. Although Oracle has introduced a new system where every three years a Long-Term Support (LTS) release will be provided, Java 11 being the first one, many organizations have been slow to move to this new model. 

Backward Compatibility: 

Some features introduced after Java 8, such as modularization with Project Jigsaw in Java 9, might break existing systems. Many companies prefer to stick with Java 8 to avoid the costs associated with making their existing code compatible with newer versions. 

Library and Framework Support: 

Not all libraries, tools, and frameworks are immediately updated to support newer Java versions, which may cause compatibility issues. 

Licensing and Commercial Support: 

Oracle changed its licensing terms starting with Java 11, which also impacts updates and support. Some organizations may find sticking with Java 8 or using alternative builds of later Java versions (like those provided by AdoptOpenJDK) more suitable for their needs. 

Cost of Upgrade: 

Upgrading to a newer Java version can be costly for a business. It involves not just replacing the runtime environment, but also testing to ensure that existing applications work correctly. 

6. Important Java Features Release-wise

Let's look at some of the major features introduced in each major release of Java, from Java 1 to Java 20.

Java 1 (1996) – JDK 1.0 (Oak) 

Java 1 was released on January 23, 1996.
Here are the important Java 1 features:
  • The initial release of Java. 
  • Basic features like primitive data types, threads and locks, exception handling, and garbage collection. 

Java 1.1 (1997) 

Java 1.1 was released on February 19, 1997
Here are the important Java 1.1 features:
  • Addition of JDBC, inner classes, Java Beans, RMI, and reflection. 
  • Improvements to the Java Libraries, such as the Collections framework. 

Java 1.2 (1998) - J2SE 

Java 1.2 was released on December 8, 1998
Here are the important Java 1.2 features:
  • Introduced a stricter security model.
  • Added Just-in-Time (JIT) compiler. 
  • Added Swing API for building GUIs. 

Java 1.3 (2000) - Kestrel 

Java 1.3 was released on May 8, 2000
Here are the important Java 1.3 features:
  • HotSpot JVM was introduced to improve performance. 
  • Java Sound, Java Naming, and Directory Interface (JNDI) were added. 

Java 1.4 (2002) - Merlin 

Java 1.4 was released on February 6, 2002
Here are the important Java 1.4 features:
  • Regular expressions, XML processing, logging API. 
  • Introduced NIO (New Input/Output) for better I/O operations. 
  • The Assert keyword was introduced. 

Java 1.5 / Java 5 (2004) - Tiger 

Java 1.5 was released on September 30, 2004
Here are the important Java 1.5 features:
  • Major changes with the introduction of generics, annotations, autoboxing, var-args, enums, formatted I/O, static import, and concurrency utilities. 

Java 1.6 / Java 6 (2006) - Mustang 

Java 1.6 was released on December 11, 2006
Here are the important Java 1.6 features:
  • Improved web service support. 
  • Scripting language support. 
  • Compiler API, pluggable annotations. 
  • Many GUI enhancements. 

Java 1.7 / Java 7 (2011) - Dolphin 

Java 1.7 was released on July 28, 2011
Here are the important Java 1.7 features:
  • JVM support for dynamically-typed languages. 
  • The new File I/O library. 
  • Support for handling multiple exceptions in a single catch block. 
  • Support for binary integer literals underscores in numeric literals, and type inference in generic instance creation. 

Java 1.8 / Java 8 (2014) - The major game-changer [LTS] 

Java 1.8 was released on March 18, 2014
Here are the important Java 1.8 features:
  • Lambda expressions and functional interfaces. 
  • Method references
  • Stream API for processing collections. 
  • Date and Time API. 
  • Default and static methods in interfaces. 
  • Nashorn – JavaScript runtime which allows developers to embed JavaScript code within applications

Java 9 (2017) 

Java 1.9 was released on September 21, 2017
Here are the important Java 1.9 features:
  • The module system (JPMS - Java Platform Module System) to deal with monolithic jars issue.
  • JShell: interactive Java REPL. 
  • Improvements to Streams, Optional, and Try-With-Resources. 
  • Private methods in interfaces. 
  • HTTP 2 Client.

Java 10 (2018) 

Java 10 was released on March 20, 2018
Here are the important Java 10 features:
  • Local-variable type inference (var keyword). 
  • Experimental JIT compiler, Graal. 
  • Docker awareness. 
  • Garbage-Collector Interface
  • Heap Allocation on Alternative Memory Devices
  • Additional Unicode Language-Tag Extensions
  • Thread-Local Handshakes

Java 11 (2018) - [LTS] 

Java 11 was released on 25th September 2018
Here are the important Java 11 features:
  • HTTP/2 Client API. 
  • Epsilon: a no-op garbage collector. 
  • Flight Recorder, which was previously a commercial feature, was open-sourced. 
  • Local-variable syntax for lambda parameters.
  • String API Changes, Collection.toArray(IntFunction), Files.readString(), Files.writeString() and Optional.isEmpty()

Java 12 (2019) 

Java 12 was released on 19th March 2019
Here are the important Java 12 features:
  • Switch Expressions (preview). 
  • Shenandoah: A low-pause-time garbage collector. 
  • Support for Unicode 11

Java 13 (2019) 

Java 13 was released on 17th September 2019
Here are the important Java 13 features:
  • Text blocks (preview). 
  • Switch expressions enhancements (preview). 
  • Reimplement the Legacy Socket API

Java 14 (2020) 

Java 14 was released on 17th March 2020
Here are the important Java 14 features:
  • Pattern matching for instanceof (preview). 
  • Records (preview), which is a special kind of lightweight, immutable data class. 
  • Text blocks and Switch expressions moved to a standard feature. 

Java 15 (2020) 

Java 15 was released on 16th September 2020
Here are the important Java 15 features:
  • Sealed classes (preview), which limit which other classes may extend or implement them. 
  • The second preview of records and pattern matching for instanceof. 
  • Removal of Nashorn JavaScript Engine and Solaris/SPARC Ports. 

Java 16 (2021) 

Java 16 was released on 16th March 2021
Here are the important Java 16 features:
  • Records and Pattern Matching for instanceof became standard features. 
  • Introduction of Sealed Interfaces. 
  • Vector API (Incubator) 
  • Concurrent Thread-Stack Processing

Java 17 (2021) - [LTS]  

Java 17 was released on 14th September 2021
Here are the important Java 17 features:
  • Sealed Classes and Interfaces moved to standard. 
  • Deprecation of the Security Manager for removal in a future release. 
  • Strong encapsulation for JDK internals.
  • Deprecate the Applet API for Removal 
  • Pattern Matching for the switch (Preview) 
  • Remove RMI Activation 
  • Sealed Classes
  • Remove the Experimental AOT and JIT Compiler
  • Foreign Function & Memory API (Incubator) 
  • Vector API (Second Incubator) 
  • Context-Specific Deserialization Filters

Java 18 (2022) 

Java 18 was released on 22nd March 2022
Here are the important Java 18 features:
  • UTF-8 by Default
  • Reimplement Core Reflection with Method Handles
  • Vector API (Third Incubator)
  • Pattern Matching for Switch 
  • Improvements to Javac Compiler 
  • Expand Checks of Javac’s Serial Lint Warning in the newest version of Java 
  • Code Snippets in Java API Documentation 
  • String Deduplication 
  • Finalization Deprecated for Removal 1.7. Internet-Address Resolution SPI 
  • Simple Web Server

Java 19 (2022) 

Java 19 was released on 20th September 2022
Here are the important Java 19 features:
  • Virtual Threads (Preview)
  • Structured Concurrency (Incubator)
  • Record Patterns (Preview)
  • Pattern Matching for the switch (Third Preview)
  • Foreign Function & Memory API (Preview)
  • Vector API (Fourth Incubator)

Java 20 (2022) 

Java 20 was released on 21st March 2023
Here are the important Java 20 features:
  • Scoped Values (Incubator)
  • Record Patterns (Second Preview) 
  • Pattern Matching for the switch (Fourth Preview) 
  • Foreign Function & Memory API (Second Preview)
  • Virtual Threads (Second Preview)
  • Structured Concurrency (Second Incubator) 
  • Vector API (Fifth Incubator)

Java 21 Features (2023) [LTS] 

Java 21 is set to be released on 19-Sep-2023, as the next long-term support (LTS) release of Oracle’s standard Java implementation. 

Java 21 will have the following features: 
  • String Templates (Preview)
  • Sequenced Collections
  • Generational ZGC 
  • Record Patterns 
  • Pattern Matching for switch 
  • Foreign Function & Memory API (Third Preview) 
  • Unnamed Patterns and Variables (Preview) 
  • Virtual Threads
  • Unnamed Classes and Instance Main Methods (Preview)
  • Scoped Values (Preview) 
  • Vector API (Sixth Incubator) 
  • Deprecate the Windows 32-bit x86 Port for Removal 
  • Prepare to Disallow the Dynamic Loading of Agents 
  • Key Encapsulation Mechanism API 
  • Structured Concurrency (Preview)

Comments