intermediateAsync Programming with @Async
Why return CompletableFuture instead of void from an @Async method?
A void @Async method is pure fire-and-forget — the caller has no way to know when it finished or get its result. Returning CompletableFuture<T> lets the caller compose multiple async calls together and retrieve the result once it's ready, without blocking immediately.
This is a Pro chapter
Sign in, then upgrade to Pro or Power to unlock this and the full Spring Ecosystem Mastery library.
Why return CompletableFuture instead of void from an @Async method?