Оглавление:
Evolution of Java language v1–v25: key features
Legend
✅ — Production (can be used in production)
⚠️ — Preview / Incubator (experimental, not for production, version when it became Production is indicated in parentheses)
Version Table
Version
Main Innovations
Comment / Value
Super Solution (%)
Java 1.0 (1996)
- Basic syntax ✅
- Standard library ✅
- Standard library ✅
The first version of Java, the foundation of the entire language, creating cross-platform applications
20
Java 1.1 (1997)
- Inner classes ✅
- JavaBeans ✅
- JDBC API ✅
- JavaBeans ✅
- JDBC API ✅
Simplification of application architecture, database connectivity
30
Java 1.2 (1998)
- Swing GUI ✅
- Collections Framework ✅
- JIT compilation improved ✅
- Collections Framework ✅
- JIT compilation improved ✅
A big step for desktop applications, convenient work with collections
40
Java 1.3 (2000)
- HotSpot improvements ✅
- Java Sound API ✅
- JNDI ✅
- Java Sound API ✅
- JNDI ✅
Optimization of the JVM, new APIs for multimedia and networking
45
Java 1.4 (2002)
- assert ✅
- Logging API ✅
- NIO (New IO) ✅
- Logging API ✅
- NIO (New IO) ✅
Convenient tools for debugging, new input-output capabilities
50
Java 5 (2004)
- Generics ✅
- Enum ✅
- Annotations ✅
- Enhanced for-loop ✅
- Varargs ✅
- Enum ✅
- Annotations ✅
- Enhanced for-loop ✅
- Varargs ✅
The first syntactical revolution, reducing boilerplate, new types and constructs
50
Java 6 (2006)
- Scripting API ✅
- JDBC 4.0 ✅
- JVM improvements ✅
- JDBC 4.0 ✅
- JVM improvements ✅
Minor improvements in the platform and performance, integration with scripts
55
Java 7 (2011)
- try-with-resources ✅
- Diamond operator ✅ (new HashMap<💎>();)
- NIO2 ✅
- Fork/Join framework ✅
- Diamond operator ✅ (new HashMap<💎>();)
- NIO2 ✅
- Fork/Join framework ✅
Major improvements in syntax and parallelism, convenient resource management
60
Java 8 (2014, LTS)
- Lambda expressions ✅
- Stream API ✅
- java.time ✅
- default methods in interfaces ✅
- Optional ✅
- CompletableFuture ✅
- Stream API ✅
- java.time ✅
- default methods in interfaces ✅
- Optional ✅
- CompletableFuture ✅
The first major functional revolution, simplifying collection handling, introducing a functional style
90
Java 9 (2017)
- Module System (Jigsaw) ✅
- JShell (REPL) ✅ interactive environment for Java
- Improvements to Stream API ✅ A java.util.concurrent.Flow package appeared, 4 basic interfaces (Publisher, Subscriber, Subscription, Processor).
- JShell (REPL) ✅ interactive environment for Java
- Improvements to Stream API ✅ A java.util.concurrent.Flow package appeared, 4 basic interfaces (Publisher, Subscriber, Subscription, Processor).
Allows for the creation of modular applications, easing the maintenance of large projects
70
Java 10 (2018)
- Local-Variable Type Inference (`var`) ✅
- GC improvements ✅
- GC improvements ✅
Reduces boilerplate code, minor JVM optimizations
50
Java 11 (2018, LTS)
- New HTTP Client ✅
- Single file programs ✅
- Removal of Java EE / CORBA ✅
- Single file programs ✅
- Removal of Java EE / CORBA ✅
Simplifies network requests and microservice development, simplifies distribution
60
Java 12 (2019)
- Switch Expressions ⚠️ (Production with Java 14)
- JVM Constants API ✅
- Shenandoah GC (experimental) ⚠️ (Production with Java 15)
- JVM Constants API ✅
- Shenandoah GC (experimental) ⚠️ (Production with Java 15)
The new switch syntax simplifies code, testing new GCs
50
Java 13 (2019)
- Text Blocks ⚠️ (Production with Java 15)
- Dynamic CDS Archives ✅
- Dynamic CDS Archives ✅
Convenient creation of multi-line text, faster JVM startup
55
Java 14 (2020)
- Records ⚠️ (Production with Java 16)
- Pattern Matching instanceof ⚠️ (Production with Java 16)
- NVM API ⚠️
- Pattern Matching instanceof ⚠️ (Production with Java 16)
- NVM API ⚠️
Compact immutable classes, simplifies type checking
75
Java 15 (2020)
- Sealed Classes ⚠️ (Production with Java 17)
- Hidden Classes ✅
- Text Blocks stabilized ✅
- Hidden Classes ✅
- Text Blocks stabilized ✅
Control over inheritance, simplification of frameworks
65
Java 16 (2021)
- Records and Pattern Matching confirmed ✅
- Vector API ⚠️ (Production with Java 17)
- jpackage ✅
- Vector API ⚠️ (Production with Java 17)
- jpackage ✅
SIMD-vector optimizations, simplification of native package builds
70
Java 17 (2021, LTS)
- Sealed Classes finalized ✅
- ZGC/G1 improvements ✅
- Foreign Function & Memory API ⚠️ (Production with Java 25)
- ZGC/G1 improvements ✅
- Foreign Function & Memory API ⚠️ (Production with Java 25)
New GCs and safe handling of external libraries and memory
80
Java 18 (2022)
- Simple Web Server ✅
- UTF-8 by default ✅
- Pattern Matching switch ⚠️ (Production with Java 21)
- UTF-8 by default ✅
- Pattern Matching switch ⚠️ (Production with Java 21)
Fast development and testing, simplifying text work
55
Java 19 (2022)
- Virtual Threads ⚠️ (Production with Java 21)
- Structured Concurrency API ⚠️ (Production with Java 25)
- Record Patterns ⚠️ (Production with Java 21)
- Structured Concurrency API ⚠️ (Production with Java 25)
- Record Patterns ⚠️ (Production with Java 21)
A key step towards safe high-concurrency processing
95
Java 20 (2023)
- Scoped Values ⚠️ (Production with Java 25)
- Pattern Matching extended ✅
- Virtual Threads stabilize ⚠️ (Production with Java 21)
- Pattern Matching extended ✅
- Virtual Threads stabilize ⚠️ (Production with Java 21)
Safe state propagation across threads
90
Java 21 (2023, LTS)
- Virtual Threads finalized ✅
- Record Patterns & Pattern Matching extended ✅
- Sequenced Collections API ✅ -- SequencedMap / SequencedSet
- Record Patterns & Pattern Matching extended ✅
- Sequenced Collections API ✅ -- SequencedMap / SequencedSet
Massive simplification of multithreading, improvements in collections and syntax
100
Java 22–24 (2024-2025, non-LTS)
- Foreign Function & Memory API improved ✅
- New GCs and performance ✅
- Structured Concurrency extensions ⚠️ (Production with Java 25)
- New GCs and performance ✅
- Structured Concurrency extensions ⚠️ (Production with Java 25)
Direct access to native libraries, JVM optimization
85
Java 25 (2025)
- Loom & Project Panama improved ✅
- Virtual Threads and Structured Concurrency production ✅
- New async APIs ✅
- Virtual Threads and Structured Concurrency production ✅
- New async APIs ✅
Full safe high-performance multithreading and interaction with native systems
95
Sealed Classes
// Parent class
public sealed class Shape permits Circle, Rectangle { }
// Allowed subclasses
public final class Circle extends Shape { }
public final class Rectangle extends Shape { }
Text Blocks
String json = """
{
"name": "Alice",
"age": 30
}
""";
System.out.println(json)
Scoped Values
try (var scope = ScopedValue.where("user", "Alice")) {
new Thread(() -> {
System.out.println(ScopedValue.get("user")); // Alice — inherited
}).start();
} // scope closes, value disappears
Record Pattern
Object obj = new PersonRecord("Alice", 30);
if (obj instanceof PersonRecord(String name, int age)) {
System.out.println(name + " " + age); // unpacked immediately
}
Pattern Matching for switch
switch (obj) {
case PersonRecord(String n, int a) when a >= 18 -> System.out.println(n + " is adult");
case PersonRecord(String n, int a) -> System.out.println(n + " is minor");
default -> System.out.println("Unknown");
}
Project Panama
import java.foreign.*;
CLinker linker = CLinker.systemCLinker();
Symbol lookup = linker.lookup("printf");
//You can directly call printf from C without JNI templates.
// supported C, C++, Rust, Fortran, Assembler (via C ABI)
Test - Check your knowledge about which version of Java introduced key features and changes.
Оставить комментарий
Мой канал в социальных сетях
Полезные статьи:
Memory model is a layer between the program and the processor. Modern CPUs aggressively optimize execution: instructions may be reordered, data may be stored in core caches, and operations may be perf…
In this article we will analyze advanced type system features in Go: generics (type parameters), reflection, and channel types for concurrency. We will compare Go and Java approaches, so Java develope…
In this article, we gathered the key low-level mechanisms of Go that most often raise questions for developers coming from Java. We will consider: unsafe.Pointer, struct alignment, pointer arithmetic,…
Новые статьи:
Concurrency is not about “starting many threads”. It’s about agreements between them. Imagine a restaurant kitchen: — cooks (threads / goroutines) — orders (tasks) — and the main question: how do th…
Imagine a typical production service. 32 CPU hundreds of threads configuration / session / rate limits cache tens of thousands of operations per second And somewhere inside — a regular Map. At first…
Zero Allocation — is an approach to writing code in which no unnecessary objects are created in heap memory during runtime. The main idea: fewer objects → less GC → higher stability and performance. …