Java 19 has only 7 new features.
|405:||Record Patterns (Preview) Record Patterns|
|422:||Linux/RISC-V Port Linux/RISC-V porting|
|424:||Foreign Function & Memory API (Preview) External Function and Memory API|
|425:||Virtual Threads (Preview) Virtual Threads|
|426:||Vector API (Fourth Incubator) Vector API|
|427:||Pattern Matching for switch (Third Preview) Switch Pattern Matching|
|428:||Structured Concurrency (Incubator) Structured Concurrency|
The following is a short description of the new features.
Record mode (preview version)
Enhance the Java programming language to deconstruct record values with Record Patterns, which can nest record patterns and type patterns to enable powerful, declarative and composable forms of data navigation and processing.
This is a preview language feature.
Porting the JDK to Linux/RISC-V currently only supports the RV64GV configuration of RISC-V (a generic 64-bit ISA containing vector instructions). Support for other RISC-V configurations, such as the generic 32-bit configuration (RV32G), may be considered in the future.
External Functions and Memory API (Preview)
Introduces an API through which Java programs can interoperate with code and data outside of the Java runtime. The API enables efficient calls to external functions (code outside the JVM) and safe access to external memory (memory not managed by the JVM), allowing Java programs to call native libraries and work with native data without the vulnerabilities and dangers of JNI.
This is a preview API.
Virtual Threading (Preview)
Introduces virtual threading to the Java platform. Virtual threads are lightweight threads that significantly reduce the effort of writing, maintaining and observing high-throughput concurrent applications.
This is a preview API, which we at OSC have described in detail.
Vector API (fourth incubation)
Introduces an API to express vector computation that compiles reliably at runtime, optimising vector instructions on supported CPU architectures to achieve better performance than scalar computation.
Switch Pattern Matching (3rd preview version)
Enhances the Java programming language with pattern matching of
switch expressions and statements, and extensions to the pattern language. Extending pattern matching to
switch allows expressions to be tested against a number of patterns so that complex data-oriented queries can be expressed concisely and safely.
This feature first appeared as a preview in Java 17, with Java 19 being the third preview.
Structured concurrency (incubation phase)
Simplify multi-threaded programming by introducing an API for structured concurrency, which treats multiple tasks running in different threads as a single unit of work, thereby simplifying error handling, improving reliability and enhancing observability.
This is an incubation stage API.
Also attached JDK 19 Timeline:
|2022/06/09||Rampdown Phase One Rampdown Phase One (fork from main line)|
|2022/07/21||Rampdown Phase Two Rampdown Phase Two|
|2022/08/11||Initial Release Candidate Initial Candidate Version (RC)|
|2022/08/25||Final Release Candidate Final Release Candidate ( RC)|
|2022/09/20||General Availability stable release|
The Rampdown is mainly a bug fixing and testing phase.
Another interesting thing: starting with Java 16, the number of features per release gets smaller and smaller: * Java 16: 17 features
- Java 16: 17
- Java 17: 14
- Java 18: 9
- Java 19: 7