Java 21 is brewing

Java Development Kit (JDK) 21, due in September as the next long-term support release of Oracle’s standard Java implementation, now has 16 features officially proposed for it, with three more features added in recent days.

The latest proposals include previews of structured concurrency and scoped values and preparations to disallow the dynamic loading of agents. Other recently added features include a key encapsulation mechanism (KEM) API and deprecation of the 32-bit x86 Windows port. Three other features—a generational Shenandoah garbage collector, unnamed classes and instance main methods, and unnamed patterns and variables—also were added last month.

These five proposals join eight features proposed in March and April: a generational ZGC (Z Garbage Collector), record patterns, pattern matching for switch expressions and statements, a vector API, sequenced collections, virtual threads, a preview of string templates, and a third preview of a foreign function and memory API. Separately, JDK 21 also is due to change how network names are assigned to network interfaces on Windows. The feature set is due to be frozen on June 8, as part of an initial rampdown phase.

Early-access binaries under the GPL are available at jdk.java.net. Oracle publishes new releases of standard Java every six months, with the most recent, JDK 20, having arrived March 21. The specific proposals for JDK 21 so far include: