JDK 22: The new features in Java 22

December 1, 2023

Java Development Kit 22, due in March 2024 as the next version of Java Standard Edition, has grown to include 12 features, with a second preview of scoped values and a preview of stream gatherers being the latest additions. Oracle said the feature set for JDK 22 will be frozen by December 7.

Scoped values enable the safe and efficient sharing of immutable data within and across threads. These are preferred to thread-local variables, especially when using large numbers of thread variables. Goals include ease of use, comprehensibility, robustness, and performance.

Stream gatherers, also a preview feature, would enhance the stream API to support custom intermediate operations. This will allow stream pipelines to transform data in ways not easily achievable with existing built-in intermediate operations.

To read this article in full, please click here

InfoWorld 

Article Categories:
Uncategorized

Leave a Reply

Your email address will not be published. Required fields are marked *

Generated by Feedzy