Menu

Java and Kotlin news: JDK 28 gets structured concurrency and AOT code
📰

Java and Kotlin news: JDK 28 gets structured concurrency and AOT code

DEV Community: java·Dmitry Protsenko·1 day ago
#WUYuPFtj
#devtojava#devto#dev#kotlin#spring
Reading 0:00
15s threshold

A Spring Security upgrade quietly turns DPoP off in your Java resource server, and JDK 28 makes structured concurrency final.

This digest covers 5 to 19 October 2026.

Java

1. Structured concurrency is final (JEP 543)

Structured concurrency runs related subtasks in different threads as one unit. If one fails, the others are cancelled, and the parent can’t return while a child still runs. After seven preview rounds, StructuredTaskScope is final in JDK 28.

try ( var scope = StructuredTaskScope . open ()) { var user = scope . fork (() -> findUser ()); var order = scope . fork (() -> fetchOrder ()); scope . join (); // throws ExecutionException if a task fails return new Response ( user . get (), order . get ()); }

Enter fullscreen mode

Exit fullscreen mode

Code written for JDK 27 only drops the preview flag. Code from JDK 26 has more to change: join() throws ExecutionException instead of FailedException, and TimeoutException is gone.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.