Skip to content

Languages & Runtimes

Structured Concurrency in Practice: CoroutineScope vs StructuredTaskScope

with Filip Egeric

Friday 10 July 18:20 – 18:50 Stage 8 - powered by Red Hat

About This Session

Structured concurrency is a familiar concept to Kotlin developers, and CoroutineScope has long been the go-to tool for managing lifecycles and structuring asynchronous code in a safe, predictable way. But now, the Java ecosystem is stepping up: Java’s new StructuredTaskScope API brings structured concurrency concepts natively to the platform, and it’s capturing a lot of attention with its promise of clarity and safety in concurrent programming. Since Kotlin and Java work very well together, we'll see how we can use this new API from Kotlin and how it's better or worse from the already known CoroutineScope API. We’ll explore real-world use cases that require structured concurrency, then take a deep dive into both CoroutineScope and StructuredTaskScope. We’ll compare their APIs, features, and design philosophies.

Topics

  • Concurrency
  • Java
  • Kotlin
  • Spring Boot