OpenJDK 27, an interim release of OpenJDK, was published in the release pocket of Ubuntu 26.10 and will be supported until the Stonking Stingray end of life in July 2027. Its new features improve the performance and security of OpenJDK. In addition to that the release previews language and API improvements. Coinciding with the new release, Phoronix benchmarked OpenJDK performance across major versions.
OpenJDK 27 introduces the following new features:
- JEP 523: Make G1 the Default Garbage Collector in All Environments: Previously Hotspot JVM would use the Serial garbage collector if the heap size was below 2Gb or the machine had only one CPU. Now G1 will be selected by default.
- JEP 527: Post-Quantum Hybrid Key Exchange for TLS 1.3: OpenJDK now supports RFC 9954 - a hybrid key exchange for TLS 1.3 that should provide assurance from collect now/crack later attacks.
- JEP 534: Compact Object Headers by Default: OpenJDK 27 defaults to the Compact Object Headers. This feature reduces the memory footprint of Java applications while maintaining the same (or better) performance.
- JEP 536: JFR In-Process Data Redaction: This feature redacts out environment values and command line arguments of the application before it leaves the process, protecting the sensitive information.
In addition to those new features, OpenJDK 27 includes the following previews:
- JEP 531: Lazy Constants (Third Preview) : Improves support for high-performance mathematical operations that can take advantage of modern CPU vector capabilities
- JEP 532: Primitive Types in Patterns, instanceof, and switch
- (Fifth Preview) : Extends support for primitive types in patterns, instanceof, and switch, letting developers write cleaner type and value checks including for types like int and boolean
- JEP 533: Structured Concurrency (Seventh Preview) : Refines the API for structured concurrency, treating groups of related tasks running in different threads as single units of work, streamlining error handling and cancellation, improving reliability, and enhancing observability
- JEP 537: Vector API (Twelfth Incubator): Improves support for high-performance mathematical operations that can take advantage of modern CPU vector capabilities
- JEP 538: PEM Encodings of Cryptographic Objects (Third Preview): Introduces support for PEM file format.
You can read more about the new features here.