Blame SOURCES/NEWS

d1af5a
Key:
d1af5a
d1af5a
JDK-X  - https://bugs.openjdk.java.net/browse/JDK-X
d1af5a
CVE-XXXX-YYYY: https://cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY
d1af5a
d1af5a
New in release OpenJDK 17.0.0 (2021-09-14):
d1af5a
===========================================
d1af5a
The full list of changes in the interim releases from 11u to 17u can be found at:
d1af5a
  * https://builds.shipilev.net/backports-monitor/release-notes-12.txt
d1af5a
  * https://builds.shipilev.net/backports-monitor/release-notes-13.txt
d1af5a
  * https://builds.shipilev.net/backports-monitor/release-notes-14.txt
d1af5a
  * https://builds.shipilev.net/backports-monitor/release-notes-15.txt
d1af5a
  * https://builds.shipilev.net/backports-monitor/release-notes-16.txt
d1af5a
  * https://builds.shipilev.net/backports-monitor/release-notes-17.txt
d1af5a
d1af5a
Major changes are listed below.  Some changes may have been backported
d1af5a
to earlier releases following their first appearance in OpenJDK 12
d1af5a
through to 17.
d1af5a
d1af5a
NEW FEATURES
d1af5a
============
d1af5a
d1af5a
Language Features
d1af5a
=================
d1af5a
d1af5a
Switch Expressions
d1af5a
==================
d1af5a
https://openjdk.java.net/jeps/325
d1af5a
https://openjdk.java.net/jeps/354
d1af5a
https://openjdk.java.net/jeps/361
d1af5a
d1af5a
Extend the `switch` statement so that it can be used as either a
d1af5a
statement or an expression, and that both forms can use either a
d1af5a
"traditional" or "simplified" scoping and control flow behavior.  Both
d1af5a
forms can use either traditional `case ... :` labels (with fall
d1af5a
through) or new `case ... ->` labels (with no fall through), with a
d1af5a
further new statement for yielding a value from a `switch`
d1af5a
expression. These changes will simplify everyday coding, and also
d1af5a
prepare the way for the use of pattern matching in `switch`.
d1af5a
d1af5a
This was a preview feature (http://openjdk.java.net/jeps/12) in
d1af5a
OpenJDK 12 & 13 and became final in OpenJDK 14.
d1af5a
d1af5a
Text Blocks
d1af5a
===========
d1af5a
https://openjdk.java.net/jeps/355
d1af5a
https://openjdk.java.net/jeps/368
d1af5a
https://openjdk.java.net/jeps/378
d1af5a
d1af5a
Add text blocks to the Java language. A text block is a multi-line
d1af5a
string literal that avoids the need for most escape sequences,
d1af5a
automatically formats the string in a predictable way, and gives the
d1af5a
developer control over format when desired.
d1af5a
d1af5a
This was a preview feature (http://openjdk.java.net/jeps/12) in
d1af5a
OpenJDK 13 & 14 and became final in OpenJDK 15.
d1af5a
d1af5a
Pattern Matching for instanceof
d1af5a
===============================
d1af5a
https://openjdk.java.net/jeps/305
d1af5a
https://openjdk.java.net/jeps/375
d1af5a
https://openjdk.java.net/jeps/394
d1af5a
http://cr.openjdk.java.net/~briangoetz/amber/pattern-match.html
d1af5a
d1af5a
Enhance the Java programming language with pattern matching for the
d1af5a
`instanceof` operator. Pattern matching allows common logic in a
d1af5a
program, namely the conditional extraction of components from objects,
d1af5a
to be expressed more concisely and safely.
d1af5a
d1af5a
This was a preview feature (http://openjdk.java.net/jeps/12) in
d1af5a
OpenJDK 14 & 15 and became final in OpenJDK 16.
d1af5a
d1af5a
Records
d1af5a
=======
d1af5a
https://openjdk.java.net/jeps/359
d1af5a
https://openjdk.java.net/jeps/384
d1af5a
https://openjdk.java.net/jeps/395
d1af5a
d1af5a
Enhance the Java programming language with records.  Records provide a
d1af5a
compact syntax for declaring classes which are transparent holders for
d1af5a
shallowly immutable data.
d1af5a
d1af5a
This was a preview feature (http://openjdk.java.net/jeps/12) in
d1af5a
OpenJDK 14 & 15 and became final in OpenJDK 16.
d1af5a
d1af5a
Sealed Classes
d1af5a
==============
d1af5a
https://openjdk.java.net/jeps/360
d1af5a
https://openjdk.java.net/jeps/397
d1af5a
https://openjdk.java.net/jeps/409
d1af5a
https://cr.openjdk.java.net/~briangoetz/amber/datum.html
d1af5a
d1af5a
Enhance the Java programming language with sealed classes and
d1af5a
interfaces. Sealed classes and interfaces restrict which other classes
d1af5a
or interfaces may extend or implement them.
d1af5a
d1af5a
This was a preview feature (http://openjdk.java.net/jeps/12) in
d1af5a
OpenJDK 15 & 16 and became final in OpenJDK 17.
d1af5a
d1af5a
Restore Always-Strict Floating-Point Semantics
d1af5a
==============================================
d1af5a
https://openjdk.java.net/jeps/306
d1af5a
d1af5a
Make floating-point operations consistently strict, rather than have
d1af5a
both strict floating-point semantics (`strictfp`) and subtly different
d1af5a
default floating-point semantics. This will restore the original
d1af5a
floating-point semantics to the language and VM, matching the
d1af5a
semantics before the introduction of strict and default floating-point
d1af5a
modes in Java SE 1.2.
d1af5a
d1af5a
Pattern Matching for switch
d1af5a
===========================
d1af5a
https://openjdk.java.net/jeps/406
d1af5a
d1af5a
Enhance the Java programming language with pattern matching for
d1af5a
`switch` expressions and statements, along with extensions to the
d1af5a
language of patterns. Extending pattern matching to `switch` allows an
d1af5a
expression to be tested against a number of patterns, each with a
d1af5a
specific action, so that complex data-oriented queries can be
d1af5a
expressed concisely and safely.
d1af5a
d1af5a
This is a preview feature (http://openjdk.java.net/jeps/12) in OpenJDK
d1af5a
17.
d1af5a
d1af5a
Library Features
d1af5a
================
d1af5a
d1af5a
JVM Constants API
d1af5a
=================
d1af5a
https://openjdk.java.net/jeps/334
d1af5a
d1af5a
Introduce an API to model nominal descriptions of key class-file and
d1af5a
run-time artifacts, in particular constants that are loadable from the
d1af5a
constant pool.
d1af5a
d1af5a
Reimplement the Legacy Socket API
d1af5a
=================================
d1af5a
https://openjdk.java.net/jeps/353
d1af5a
d1af5a
Replace the underlying implementation used by the `java.net.Socket`
d1af5a
and `java.net.ServerSocket` APIs with a simpler and more modern
d1af5a
implementation that is easy to maintain and debug. The new
d1af5a
implementation will be easy to adapt to work with user-mode threads,
d1af5a
a.k.a. fibers, currently being explored in Project Loom
d1af5a
(https://openjdk.java.net/projects/loom).
d1af5a
d1af5a
JFR Event Streaming
d1af5a
===================
d1af5a
https://openjdk.java.net/jeps/349
d1af5a
d1af5a
Expose JDK Flight Recorder data for continuous monitoring.
d1af5a
d1af5a
Non-Volatile Mapped Byte Buffers
d1af5a
================================
d1af5a
https://openjdk.java.net/jeps/352
d1af5a
d1af5a
Add new JDK-specific file mapping modes so that the `FileChannel` API
d1af5a
can be used to create `MappedByteBuffer` instances that refer to
d1af5a
non-volatile memory.
d1af5a
d1af5a
Helpful NullPointerExceptions
d1af5a
=============================
d1af5a
https://openjdk.java.net/jeps/358
d1af5a
d1af5a
Improve the usability of `NullPointerException`s generated by the JVM
d1af5a
by describing precisely which variable was `null`.
d1af5a
d1af5a
Foreign-Memory Access API
d1af5a
=========================
d1af5a
https://openjdk.java.net/jeps/370
d1af5a
https://openjdk.java.net/jeps/383
d1af5a
https://openjdk.java.net/jeps/393
d1af5a
d1af5a
Introduce an API to allow Java programs to safely and efficiently
d1af5a
access foreign memory outside of the Java heap.
d1af5a
d1af5a
This was a incubation feature (https://openjdk.java.net/jeps/11) in
d1af5a
OpenJDK 14, 15 & 16, now superseded by the Foreign Function & Memory
d1af5a
API in OpenJDK 17 (see below).
d1af5a
d1af5a
Edwards-Curve Digital Signature Algorithm (EdDSA)
d1af5a
=================================================
d1af5a
https://openjdk.java.net/jeps/339
d1af5a
d1af5a
Implement cryptographic signatures using the Edwards-Curve Digital
d1af5a
Signature Algorithm (EdDSA) as described by RFC 8032
d1af5a
(https://tools.ietf.org/html/rfc8032).
d1af5a
d1af5a
Hidden Classes
d1af5a
==============
d1af5a
https://openjdk.java.net/jeps/371
d1af5a
d1af5a
Introduce hidden classes, which are classes that cannot be used
d1af5a
directly by the bytecode of other classes. Hidden classes are intended
d1af5a
for use by frameworks that generate classes at run time and use them
d1af5a
indirectly, via reflection. A hidden class may be defined as a member
d1af5a
of an access control nest (https://openjdk.java.net/jeps/181), and may
d1af5a
be unloaded independently of other classes.
d1af5a
d1af5a
Reimplement the Legacy DatagramSocket API
d1af5a
=========================================
d1af5a
https://openjdk.java.net/jeps/373
d1af5a
d1af5a
Replace the underlying implementations of the
d1af5a
`java.net.DatagramSocket` and `java.net.MulticastSocket` APIs with
d1af5a
simpler and more modern implementations that are easy to maintain and
d1af5a
debug. The new implementations will be easy to adapt to work with
d1af5a
virtual threads, currently being explored in Project Loom
d1af5a
(https://openjdk.java.net/projects/loom). This is a follow-on to JEP
d1af5a
353 (see above), which already reimplemented the legacy Socket API.
d1af5a
d1af5a
Vector API
d1af5a
==========
d1af5a
https://openjdk.java.net/jeps/338
d1af5a
https://openjdk.java.net/jeps/414
d1af5a
d1af5a
Provide an initial iteration of an incubator module,
d1af5a
`jdk.incubator.vector`, to express vector computations that reliably
d1af5a
compile at runtime to optimal vector hardware instructions on
d1af5a
supported CPU architectures and thus achieve superior performance to
d1af5a
equivalent scalar computations.
d1af5a
d1af5a
This is an incubation feature (https://openjdk.java.net/jeps/11)
d1af5a
introduced in OpenJDK 16.
d1af5a
d1af5a
Unix-Domain Socket Channels
d1af5a
===========================
d1af5a
https://openjdk.java.net/jeps/380
d1af5a
d1af5a
Add Unix-domain (`AF_UNIX`) socket support to the socket channel and
d1af5a
server-socket channel APIs in the `java.nio.channels` package. Extend
d1af5a
the inherited channel mechanism to support Unix-domain socket channels
d1af5a
and server socket channels.
d1af5a
d1af5a
Foreign Linker API (Incubator)
d1af5a
==============================
d1af5a
https://openjdk.java.net/jeps/389
d1af5a
d1af5a
Introduce an API that offers statically-typed, pure-Java access to
d1af5a
native code. This API, together with the Foreign-Memory API (see
d1af5a
above), will considerably simplify the otherwise error-prone process
d1af5a
of binding to a native library.
d1af5a
d1af5a
This was an incubation feature (https://openjdk.java.net/jeps/11)
d1af5a
introduced in OpenJDK 16, now superseded by the Foreign Function &
d1af5a
Memory API in OpenJDK 17 (see below).
d1af5a
d1af5a
Strongly Encapsulate JDK Internals by Default
d1af5a
=============================================
d1af5a
https://openjdk.java.net/jeps/396
d1af5a
https://openjdk.java.net/jeps/403
d1af5a
d1af5a
Strongly encapsulate all internal elements of the JDK by default,
d1af5a
except for critical internal APIs such as `sun.misc.Unsafe`.  It will
d1af5a
no longer be possible to relax the strong encapsulation of internal
d1af5a
elements via a single command-line option, as was possible in OpenJDK
d1af5a
9 through 16.
d1af5a
d1af5a
Enhanced Pseudo-Random Number Generators
d1af5a
========================================
d1af5a
https://openjdk.java.net/jeps/356
d1af5a
d1af5a
Provide new interface types and implementations for pseudo-random
d1af5a
number generators (PRNGs), including jumpable PRNGs and an additional
d1af5a
class of splittable PRNG algorithms (LXM).
d1af5a
d1af5a
Foreign Function & Memory API
d1af5a
=============================
d1af5a
https://openjdk.java.net/jeps/412
d1af5a
d1af5a
Introduce an API by which Java programs can interoperate with code and
d1af5a
data outside of the Java runtime. By efficiently invoking foreign
d1af5a
functions (i.e., code outside the JVM), and by safely accessing
d1af5a
foreign memory (i.e., memory not managed by the JVM), the API enables
d1af5a
Java programs to call native libraries and process native data without
d1af5a
the brittleness and danger of JNI.
d1af5a
d1af5a
This API is an incubation feature (https://openjdk.java.net/jeps/11)
d1af5a
introduced in OpenJDK 17, and is an evolution of the Foreign Memory
d1af5a
Access API (OpenJDK 14 through 16) and Foreign Linker API (OpenJDK
d1af5a
16) (see above).
d1af5a
d1af5a
Context-Specific Deserialization Filters
d1af5a
========================================
d1af5a
https://openjdk.java.net/jeps/415
d1af5a
d1af5a
Allow applications to configure context-specific and
d1af5a
dynamically-selected deserialization filters via a JVM-wide filter
d1af5a
factory that is invoked to select a filter for each individual
d1af5a
deserialization operation.
d1af5a
d1af5a
Tools
d1af5a
=====
d1af5a
d1af5a
Packaging Tool
d1af5a
==============
d1af5a
https://openjdk.java.net/jeps/343
d1af5a
https://openjdk.java.net/jeps/392
d1af5a
d1af5a
Provide the `jpackage` tool, for packaging self-contained Java
d1af5a
applications.
d1af5a
d1af5a
JVM Features
d1af5a
============
d1af5a
d1af5a
Shenandoah: A Low-Pause-Time Garbage Collector
d1af5a
==============================================
d1af5a
https://openjdk.java.net/jeps/189
d1af5a
https://openjdk.java.net/jeps/379
d1af5a
d1af5a
Add a new garbage collection (GC) algorithm named Shenandoah which
d1af5a
reduces GC pause times by doing evacuation work concurrently with the
d1af5a
running Java threads.  Pause times with Shenandoah are independent of
d1af5a
heap size, meaning you will have the same consistent pause times
d1af5a
whether your heap is 200 MB or 200 GB.
d1af5a
d1af5a
Shenandoah has been provided in Red Hat builds of OpenJDK 8 since
d1af5a
8u131 in April 2017 and in all 11u builds.
d1af5a
d1af5a
Upstream, it was introduced in OpenJDK 12 as an experimental feature
d1af5a
and became a production feature in OpenJDK 15. It was backported to
d1af5a
OpenJDK 11 with the 11.0.9 release in October 2020.
d1af5a
d1af5a
Abortable Mixed Collections for G1
d1af5a
==================================
d1af5a
https://openjdk.java.net/jeps/344
d1af5a
d1af5a
Make G1 mixed collections abortable if they might exceed the pause
d1af5a
target.
d1af5a
d1af5a
Promptly Return Unused Committed Memory from G1
d1af5a
===============================================
d1af5a
https://openjdk.java.net/jeps/346
d1af5a
d1af5a
Enhance the G1 garbage collector to automatically return Java heap
d1af5a
memory to the operating system when idle.
d1af5a
d1af5a
Dynamic CDS Archives
d1af5a
====================
d1af5a
https://openjdk.java.net/jeps/310
d1af5a
https://openjdk.java.net/jeps/350
d1af5a
d1af5a
Extend application class-data sharing to allow the dynamic archiving
d1af5a
of classes at the end of Java application execution. The archived
d1af5a
classes will include all loaded application classes and library
d1af5a
classes that are not present in the default, base-layer CDS archive.
d1af5a
d1af5a
ZGC: Uncommit Unused Memory (Experimental)
d1af5a
==========================================
d1af5a
https://openjdk.java.net/jeps/351
d1af5a
d1af5a
Enhance ZGC to return unused heap memory to the operating system.
d1af5a
d1af5a
NUMA-Aware Memory Allocation for G1
d1af5a
===================================
d1af5a
https://openjdk.java.net/jeps/345
d1af5a
d1af5a
Improve G1 performance on large machines by implementing NUMA-aware
d1af5a
memory allocation.
d1af5a
d1af5a
ZGC on macOS (Experimental)
d1af5a
===========================
d1af5a
https://openjdk.java.net/jeps/364
d1af5a
d1af5a
Port the ZGC garbage collector to macOS.
d1af5a
d1af5a
ZGC on Windows (Experimental)
d1af5a
=============================
d1af5a
https://openjdk.java.net/jeps/365
d1af5a
d1af5a
Port the ZGC garbage collector to Windows.
d1af5a
d1af5a
ZGC: A Scalable Low-Latency Garbage Collector (Production)
d1af5a
==========================================================
d1af5a
https://openjdk.java.net/jeps/377
d1af5a
d1af5a
Change the Z Garbage Collector from an experimental feature into a
d1af5a
product feature.
d1af5a
d1af5a
ZGC: Concurrent Thread-Stack Processing
d1af5a
=======================================
d1af5a
https://openjdk.java.net/jeps/376
d1af5a
d1af5a
Move ZGC thread-stack processing from safepoints to a concurrent
d1af5a
phase.
d1af5a
d1af5a
Elastic Metaspace
d1af5a
=================
d1af5a
https://openjdk.java.net/jeps/387
d1af5a
d1af5a
Return unused HotSpot class-metadata (i.e., metaspace) memory to the
d1af5a
operating system more promptly, reduce metaspace footprint, and
d1af5a
simplify the metaspace code in order to reduce maintenance costs.
d1af5a
d1af5a
Ports
d1af5a
=====
d1af5a
d1af5a
Alpine Linux Port
d1af5a
=================
d1af5a
https://openjdk.java.net/jeps/386
d1af5a
d1af5a
Port the JDK to Alpine Linux, and to other Linux distributions that
d1af5a
use musl as their primary C library, on both the x64 and AArch64
d1af5a
architectures,
d1af5a
d1af5a
Windows/AArch64 Port
d1af5a
====================
d1af5a
https://openjdk.java.net/jeps/388
d1af5a
d1af5a
Port the JDK to Windows/AArch64.
d1af5a
d1af5a
New macOS Rendering Pipeline
d1af5a
============================
d1af5a
https://openjdk.java.net/jeps/382
d1af5a
d1af5a
Implement a Java 2D internal rendering pipeline for macOS using the
d1af5a
Apple Metal API as alternative to the existing pipeline, which uses
d1af5a
the deprecated Apple OpenGL API.
d1af5a
d1af5a
macOS/AArch64 Port
d1af5a
==================
d1af5a
https://openjdk.java.net/jeps/391
d1af5a
d1af5a
Port the JDK to macOS/AArch64.
d1af5a
d1af5a
DEPRECATIONS
d1af5a
============
d1af5a
d1af5a
Deprecate the ParallelScavenge + SerialOld GC Combination
d1af5a
=========================================================
d1af5a
https://openjdk.java.net/jeps/366
d1af5a
d1af5a
Deprecate the combination of the Parallel Scavenge and Serial Old
d1af5a
garbage collection algorithms.
d1af5a
d1af5a
Deprecate and Disable Biased Locking
d1af5a
====================================
d1af5a
https://openjdk.java.net/jeps/374
d1af5a
d1af5a
Disable biased locking by default, and deprecate all related
d1af5a
command-line options.
d1af5a
d1af5a
Warnings for Value-Based Classes
d1af5a
================================
d1af5a
https://openjdk.java.net/jeps/390
d1af5a
d1af5a
Designate the primitive wrapper classes as value-based and deprecate
d1af5a
their constructors for removal, prompting new deprecation
d1af5a
warnings. Provide warnings about improper attempts to synchronize on
d1af5a
instances of any value-based classes in the Java Platform.
d1af5a
d1af5a
Deprecate the Applet API for Removal
d1af5a
====================================
d1af5a
https://openjdk.java.net/jeps/398
d1af5a
d1af5a
Deprecate the Applet API for removal.  It is essentially irrelevant
d1af5a
since all web-browser vendors have either removed support for Java
d1af5a
browser plug-ins or announced plans to do so.
d1af5a
d1af5a
Deprecate the Security Manager for Removal
d1af5a
==========================================
d1af5a
https://openjdk.java.net/jeps/411
d1af5a
d1af5a
Deprecate the Security Manager for removal in a future release. The
d1af5a
Security Manager dates from Java 1.0. It has not been the primary
d1af5a
means of securing client-side Java code for many years, and it has
d1af5a
rarely been used to secure server-side code. To move Java forward, we
d1af5a
intend to deprecate the Security Manager for removal in concert with
d1af5a
the legacy Applet API (see above).  .
d1af5a
d1af5a
REMOVALS
d1af5a
========
d1af5a
d1af5a
Remove the Concurrent Mark Sweep (CMS) Garbage Collector
d1af5a
========================================================
d1af5a
https://openjdk.java.net/jeps/363
d1af5a
d1af5a
Remove the Concurrent Mark Sweep (CMS) garbage collector.
d1af5a
d1af5a
Remove the Pack200 Tools and API
d1af5a
================================
d1af5a
https://openjdk.java.net/jeps/336
d1af5a
https://openjdk.java.net/jeps/367
d1af5a
d1af5a
Remove the `pack200` and `unpack200` tools, and the `Pack200` API in
d1af5a
the `java.util.jar` package.  These tools and API were deprecated for
d1af5a
removal in OpenJDK 11 with the express intent to remove them in a
d1af5a
future release.
d1af5a
d1af5a
Remove the Nashorn JavaScript Engine
d1af5a
====================================
d1af5a
https://openjdk.java.net/jeps/372
d1af5a
d1af5a
Remove the Nashorn JavaScript script engine and APIs, and the `jjs`
d1af5a
tool. The engine, the APIs, and the tool were deprecated for removal
d1af5a
in OpenJDK 11 with the express intent to remove them in a future
d1af5a
release.
d1af5a
d1af5a
Remove the Solaris and SPARC Ports
d1af5a
==================================
d1af5a
https://openjdk.java.net/jeps/362
d1af5a
https://openjdk.java.net/jeps/381
d1af5a
d1af5a
Remove the source code and build support for the Solaris/SPARC,
d1af5a
Solaris/x64, and Linux/SPARC ports.  These ports were deprecated for
d1af5a
removal in OpenJDK 14 (JEP 362) and removed in OpenJDK 15 (JEP 381).
d1af5a
d1af5a
Remove RMI Activation
d1af5a
=====================
d1af5a
https://openjdk.java.net/jeps/385
d1af5a
https://openjdk.java.net/jeps/407
d1af5a
https://docs.oracle.com/en/java/javase/14/docs/specs/rmi/activation.html
d1af5a
d1af5a
Remove the Remote Method Invocation (RMI) Activation mechanism, while
d1af5a
preserving the rest of RMI.  RMI Activation is an obsolete part of RMI
d1af5a
that has been optional since OpenJDK 8 and was deprecated in OpenJDK
d1af5a
15.
d1af5a
d1af5a
Remove the Experimental AOT and JIT Compiler
d1af5a
============================================
d1af5a
https://openjdk.java.net/jeps/410
d1af5a
d1af5a
Remove the experimental Java-based ahead-of-time (AOT) and
d1af5a
just-in-time (JIT) compiler.  This compiler has seen little use since
d1af5a
its introduction and the effort required to maintain it is
d1af5a
significant.  Retain the experimental Java-level JVM compiler
d1af5a
interface (JVMCI) so that developers can continue to use
d1af5a
externally-built versions of the compiler for JIT compilation.