CompletableFuture
-
Core Java

CompletableFuture vs Virtual Threads: When to Use Each
Java 21 introduced virtual threads as a production-ready feature, fundamentally changing how we approach asynchronous programming. For years, CompletableFuture has…
Read More » -
Core Java

Transform Future into CompletableFuture
In modern Java programming, handling asynchronous tasks efficiently is a critical skill. Java provides two key abstractions for dealing with…
Read More » -
Core Java

Mastering CompletableFuture in Java: A Comprehensive Guide
CompletableFuture is a powerful and versatile tool in Java‘s arsenal for handling asynchronous computations. It offers a rich set of…
Read More » -
Core Java

Java CompletableFuture — The Flaws in allOf(…)
CompletableFuture is a powerful tool in Java’s arsenal for asynchronous programming. It represents the result of an asynchronous computation, allowing…
Read More » -
Core Java

Guide to CompletableFuture join() vs get()
Java’s CompletableFuture is a powerful tool for asynchronous programming, offering various methods to handle and manipulate future tasks. Among these…
Read More » -
Core Java

Unit Testing of ExecutorService in Java With No Thread sleep
Unit testing concurrent code, especially code utilizing ExecutorService, presents unique challenges due to its asynchronous nature. Traditional approaches often involve…
Read More » -
Core Java

The Future of Async in Java: CompletableFuture vs Virtual Threads
Asynchronous programming is a cornerstone of modern Java applications, allowing them to handle tasks without blocking the main thread. But…
Read More » -
Core Java

Which thread executes CompletableFuture’s tasks and callbacks?
CompletableFuture is still a relatively fresh concept, despite being introduced almost two years ago (!) in March 2014 with Java…
Read More »
