GeeCON 2025: Konrad Szałkowski - Organizing chaos - Structured Concurrency

youtube.com 19 godzin temu


When there’s order in our world, it’s much easier to navigate. As programmers, we rediscover this simple fact with large enthusiasm all fewer years. In Java 21, we’ve been given a fresh toy—virtual threads.

One of their main selling points is the slogan: "Create, start, forget"—an enticing promise that encourages us to make as many of these threads as possible. But we all know what happens in kids' rooms after a birthday organization or a fresh transportation of toys—chaos. This time, however, the creators of Java have tried to anticipate the mess and provided us with a brand-new API: Structured Concurrency. It’s not a groundbreaking innovation or a reinvention of the wheel, but alternatively a proven way to "organize" concurrency in our programs.

During this presentation, I’ll introduce you to the concept of Structured Concurrency, explain why it works and why it was created. I’ll besides show this code in action.