Skip to content
Sharp

Project Reactor · interview question

Given a Flux of Order objects in a non-blocking system, which transformation would you use to fetch and process order details asynchronously?

Multiple choiceHardchapter-19-curatedpremiumproject-reactorfunctional-pipelines-flatmap
Choose one answer
Answer and explanation

Correct answer

B. OrderFlux.flatMap(order -> fetchOrderDetails(order))

Why

When fetching data asynchronously, flatMap() should be used because it allows integrating asynchronous calls that return a new reactive type, enabling further non-blocking operations.

Test yourself on Project Reactor

A free test with instant, explained results. No account needed.

Start free test
All Project Reactor questions →