Java 23 introduces a mix of new features, updates, and deprecations. Notably, the String Templates feature, previewed in Java 21, has been removed for redesign due to community feedback. This marks the first time a preview feature has been pulled from a Java release. ❌📝
Key Updates:
🟣 JEP 455 adds support for primitive types in pattern matching, instanceof, and switch cases, improving versatility in handling primitive types. 🔄📊
🟣 JEP 467 allows JavaDoc comments to be written in Markdown, making documentation easier to write and read. 📝👍
🟣 JEP 471 begins the deprecation of the sun.misc.Unsafe memory-access methods, gradually replacing them with safer alternatives. 🛑🔒
🟣 JEP 474 sets ZGC's generational mode as the default for the garbage collector, optimizing performance for large heaps. 🗑️⚡
🟣 JEP 476 introduces module import declarations, simplifying importing all classes from a module in a single statement. 📦➡️
Additionally, Java 23 continues previewing several features, including class-file API enhancements, vector API improvements, stream gatherers, structured concurrency, and flexible constructor bodies. 🔄💡
The release also includes numerous internal optimizations, such as updates to the Parallel GC algorithm and various Console class improvements. 🖥️🚀
Despite these additions, Java 23 offers fewer new features, with no previously previewed features graduating to full release. 🌱
🎤 FooJay article by Loic Mathieu: https://foojay.io/today/java-23-whats-new/
☑️ Official: https://openjdk.org/projects/jdk/23/