Last updated on 2020/03/24 to include changes up to JDK 14.

Since the release of version 8, up to version 14, Java is shaped by 149 JDK Enhancement Proposals (JEPs), each of which brings some improvement to the platform. This page is a categorized and curated list of the most important improvements.

Contents of this page:

The full list of JEPs can be found on the OpenJDK website under the jdk and jdk9 projects.

All features are generally available and enabled by default, except if they are labelled with one of the following:

Preview 🔍 features are fully specified and implemented, but not yet considered to be final. They are considered to be almost complete, waiting for an additional round of real-world feedback. They have to be explicitly enabled.

🔍 features are fully specified and implemented, but not yet considered to be final. They are considered to be almost complete, waiting for an additional round of real-world feedback. They have to be explicitly enabled. Experimental 💥 features are less stable, and more likely to change. They also have to be explicitly enabled.

💥 features are less stable, and more likely to change. They also have to be explicitly enabled. Incubator 🥚 modules are non-final tools and API’s, and are distributed in separate modules.

New Language Features

When Java 8 introduced lambdas it was a pretty huge change. While recent versions did not add such impactful features, lots of smaller improvements were made to the language.

For a more in-depth guide, see New language features since Java 8.

Related New language features since Java 8 to 14 Enhancements to the Java language you should know

We write articles like this regularly. Join our mailing list and let's keep in touch.

New APIs

Let’s continue with the Java Standard Library, focusing on the new features that we can use in day-to-day coding.

If you are curious about all the API level differences between Java 8 and 14, check the AdoptOpenJDK/jdk-api-diff on GitHub.

General

Internationalization

Unicode 10.0, adding roughly 27.000 characters, 10 blocks, and more than 30 scripts

JDK 11 (Unicode 8.0 support in JDK 9)

java.util.Locale and related APIs support currency type, time zone and more

JDK 10

ResourceBundle loads properties files in UTF-8 instead of ISO-8859-1

JDK 9

CLDR Locale Data Enabled by Default

JDK 9

Graphics and Desktop Applications

Desktop features for all platforms like login/logout/lock event listener and task bar interactions

JDK 9

MultiResolutionImage that makes easy to retrieve a resolution-specific image for a DPI

JDK 9

HiDPI Graphics on Windows and Linux

JDK 9

Enable GTK 3 on Linux for JavaFX, Swing, and AWT

JDK 9

Replace @beaninfo Javadoc tags with @BeanInfo annotations for Swing

JDK 9

Update GStreamer included in JavaFX/Media to version 1.4.4

JDK 9

Replace the existing ICU OpenType font-layout engine with HarfBuzz

JDK 9

Performance Improvements

General

Foreign-Memory Access API ( Incubator 🥚)

JDK 14

Enable dynamic archiving of classes at the end of Java application execution

JDK 13

Application Class-Data Sharing to improve startup time and reduce footprint by sharing class metadata between Java processes.

JDK 10

Class-Data Sharing archive of the default class list is enabled by default to improve out-of-the-box startup time

JDK 12

Space-efficient, Compact Strings that stores Latin-1 only Strings more efficiently

JDK 9

Code caches of profiled and non-profiled compiled code is separated, resulting in improved performance and memory footprint

JDK 9

Store Interned Strings in Class-Data Sharing archives to reduce memory consumption

JDK 9

Library

Improved intrinsics for java.lang.Math sin , cos and log functions on AArch64 processors

JDK 11

Security Manager performance improvements

JDK 9

Spin-Wait Hint ( Thread#onSpinWait ) to optimize busy-waiting style loops

JDK 9

Use Marlin Renderer in Java 2D as the default graphics rasterizer instead of Pisces

JDK 9

Improved GHASH and RSA performance by leveraging recently-introduced SPARC and Intel x64 CPU instructions

JDK 9

Concurrency

Thread-Local Handshakes to stop individual threads

JDK 10

Improved performance of contended object monitors

JDK 9

Extra space on thread stack for critical sections, mitigating the risk of a deadlock in java.util.concurrent locks in case of a stack overflow

JDK 9

Compiler

Ahead-of-Time Compilation capability for Linux ( Experimental 💥)

JDK 10 (Graal as an experimental JIT Compiler) JDK 9 (JVM Compiler Interface) JDK 9 (Graal as an AoT Compiler)

Performance improvement in javac: new strategy for type checking poly expressions

JDK 9

G1 Garbage Collector (default)

NUMA-Aware Memory Allocation

JDK 14

Abortable mixed collections to meet user-supplied pause goals

JDK 12

Automatically return heap memory to the operating system when idle

JDK 12

Parallel Full GC to improve worst-case latencies

JDK 10

G1 Garbage Collector is now the default instead of Parallel GC

JDK 9

Other Garbage Collectors

Z Garbage Collector ( Experimental 💥), offering very low pause times on large heaps

JDK 14 (Windows) JDK 14 (OS X) JDK 11 (Linux) JDK 13

Shenandoah Garbage Collector ( Experimental 💥), offering similar benefits as ZGC but based on a different algorithm

JDK 12

Epsilon Garbage Collector, which does not implement actual memory reclamation, striving for the lowest overhead possible

JDK 11

XX:AllocateHeapAt=<path> to support Alternative Memory Devices

JDK 10

Flight Recorder Event Streaming: profiling data is available via an API, making it suitable for continuous monitoring

JDK 14

Microbenchmark Suite based on JMH

JDK 12

Flight Recorder is part of OpenJDK

JDK 11

Low-Overhead Heap Profiling via JMTI

JDK 11

Run-time manageable and method specific control of the C1 and C2 compilers that enables contained tests

JDK 9

Fine-grained, easy-to-configure Logging System for all components of the JVM

JDK 9 (Unified JVM Logging) JDK 9 (Unified GC Logging)

Allow the application to provide logger implementation to be used by platform classes

JDK 9

Security Improvements

Default set of root Certification Authority (CA) certificates are provided with the JDK, so TLS connections are working out of the box

JDK 10

Validate Incoming Serialization Data

JDK 9

Default keystore type is the standard PKCS12 instead of the proprietary JKS

JDK 9

DRBG-Based SecureRandom

JDK 9

Disable X.509 certificate chains with SHA-1 based signatures

JDK 9

SHA-3 Hash Algorithms

JDK 9

TLS

TLS 1.3 support

JDK 11

API for Datagram Transport Layer Security (DTLS)

JDK 9

OCSP stapling TLS to improve performance of certificate status checking

JDK 9

TLS Application-Layer Protocol Negotiation (ALPN) Extension which enables protocol negotiation without additional round trips; ALPN is a requirement for HTTP/2 connections

JDK 9

Crypto

Key Agreement with Curve25519 and Curve448

JDK 11

ChaCha20 and Poly1305 Cryptographic Algorithms

JDK 11

Launching

Launch Single-File Source-Code Programs, including support for shebang ( #! ) line on Unix

JDK 11

jshell : the Java REPL

JDK 9 (Project Kulla)

→ Related: Prototyping with JShell

Compile for Older Platform Versions with --release , which configures --source and --target and links against the appropriate platform version

JDK 9

Early validatation of JVM Command-Line Flags to avoid crashes

JDK 9

Packaging

Packaging Tool supporting native package formats: msi, exe, pkg, dmg, deb and rpm ( Incubator 🥚)

JDK 14

jlink Java Linker that can build an optimized, slim run-time image for a modular Java application thag contains only the required parts of the JDK

JDK 9 - [2], [3], [4], [4], [5]

Multi-Release JAR Files to allow multiple, Java-release-specific versions of class in a single archive

JDK 9

Javadoc

The Javadoc tool now emits HTML5 markup instead of a frame-based layout and the documentation contains a search box to ease navigation

JDK 9 - [2], [3]

Bytecode

java.lang.invoke.constant package to allow easy description of loadable constants (operands for the ldc instruction), which is less error-prone than relying on ad-hoc String representation

JDK 12

CONSTANT_Dynamic constant-pool entry which uses bootstrapping to perform the resolution, similarly to INVOKEDYNAMIC calls

JDK 11

Introduction of the Nest access-control context that wraps classes in the same code entity - such as nested classes - and eliminates the need for compiler to insert bridge methods to the generated bytecode.

JDK 11

Bytecode generated for static String-concatenation uses invokedynamic rather than directly creating StringBuilder#append chains. This will enable future optimizations of String concatenation without requiring bytecode changes.

JDK 9

INVOKEDYNAMIC can express high-level operations on object properties and or collections

JDK 9

New supported platforms

New Version Scheme

Simpler Version-String Scheme, aligned with Semantic Versioning.

JDK 9 JDK 10

Deprecation and removal

If you are curious about all the API level differences between Java 8 and 14, check the Java Almanac project. Also check out jdeps, the Java class dependency analyzer to find out if your project is still using an old internal API.

Summary

JDK 8 was released in 2014. We had to wait for three and a half years for JDK 9. But since then things accelerated. Java has a new release structure that aims to deliver a new version in every six months.

While Java 8 is still supported, migrating to the latest version brings considerable amount of improvements to the table.