Java 16 Hits General Availability
Written by Kay Ewbank   
Thursday, 18 March 2021

Java Development Kit 16 is now generally available.  Production-ready binaries under the GPL are available from Oracle; binaries from other vendors will follow shortly. Oracle has also released the new version under a commercial license for those using the Oracle JDK release as part of an Oracle product or service, or for those who want to be able to get commercial support.

The new release adds two major new features - support for Records, and Pattern Matching for the instanceof operator.


Records are classes that act as transparent carriers for immutable data, and can be thought of as nominal tuples. One reason for their addition to Java was an attempt to make the language less verbose in the hope of cutting down errors.

The addition of support for pattern matching for the instanceof operator is intended to make it possible for common logic in a program, namely the conditional extraction of components from objects, to be expressed more concisely and safely. The feature has been included as a preview feature since Java 14.

The JVM has been improved with enhanced support for concurrent thread-stack processing for the ZGC garbage collector. The processing has been moved from safepoints to a concurrent phase. The OpenJDK development team said:

"ZGC aims to make GC pauses and scalability issues in HotSpot a thing of the past. We have, so far, moved all GC operations that scale with the size of the heap and the size of metaspace out of safepoint operations and into concurrent phases. Those include marking, relocation, reference processing, class unloading, and most root processing."

Another JVM feature is elastic metaspace, a feature that returns unused HotSpot VM class-metadata (i.e. metaspace) memory to the operating system more promptly, reducing metaspace footprint. This is designed to improve memory use in applications with heavy class loading and unloading activity which until now could end up with a lot of unused space. The new scheme allocates metaspace memory in smaller chunks, and improves elasticity by returning unused metaspace memory to the operating system.

The new release also has new tools and libraries including Unix-domain socket channels and a packaging tool that allows for packaging self-contained Java applications.


More Information

JDK 16 On OpenJDK

Related Articles

Foojay - All About Java and the OpenJDK

Where's Java Going In 2020

The True State of Java and its Ecosystem

Java 15 Reaches General Availability 

Java At 25

JDK 14 Released

JDK 14 Feature Set Frozen

Where's Java Going In 2020

Java SE 13 Reaches GA

To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.


Stack Overflow Traffic Slumps As Devs Turn to ChatGTP

We are all becoming increasingly are aware of the threat to jobs across many industries from AI-powered technology. However, Stack Overflow has been an immediate casualty as developers discover the ex [ ... ]

Hinton Explains His New Fear of AI

This week Geoffrey Hinton resigned from Google in order to speak freely and warn us about the existential threat posed to humanity by AI. In this video he explains what has changed his mind after an e [ ... ]

More News





or email your comment to: