Reactive Streams interview questions
Backpressure Strategies, Blocking the Event Loop, Functional Pipelines (flatMap), Non-Blocking I/O (Event Loops), Publisher and Subscriber, Thread-Per-Request Bottleneck
120 questions with answers and explanations · 120 flashcards
Questions (page 3 of 3)
- Why is calling a blocking JDBC repository directly from a WebFlux event-loop thread dangerous?Multiple choiceHard
- Why is the 'flatMap' operator significant in a reactive stream?Multiple choiceMedium
- How does backpressure help manage data flow in a Reactive Streams system?Multiple choiceHard
- Which method would you use on a Flux to handle errors gracefully?Multiple choiceEasy
- Which component in Reactive Streams requests data from a Publisher?Multiple choiceEasy
- How would you explain a significant debugging challenge when using WebFlux compared to Java 21 Virtual Threads in an interview?Multiple choiceHard
- Why might you bound flatMap() concurrency when calling a downstream pricing service?Multiple choiceHard
- In a system using Project Reactor, what could be a consequence of using blocking operations on the event loop thread?Multiple choiceHard
- How would you explain a key challenge when debugging WebFlux applications compared to Java 21 Virtual Threads in an interview?Multiple choiceHard
- Why does the Subscriber in a Reactive Streams setup matter in this design?Multiple choiceMedium
- When using Project Reactor, why is it important to avoid blocking operations on the event loop?Multiple choiceMedium
- Why does a 'Subscriber' in the Reactive Streams specification matter in this design?Multiple choiceMedium
- In Project Reactor, what is the difference between Mono and Flux?Multiple choiceHard
- In the context of Project Reactor, what is the primary purpose of the 'publishOn' method?Multiple choiceMedium
- What potential issue arises when blocking operations are executed within a non-blocking event loop?Multiple choiceHard
- How does WebFlux handle database queries to maintain non-blocking behavior?Multiple choiceMedium
- How does the Flux type in Project Reactor differ from Mono?Multiple choiceMedium
- Which function is preferable when transforming data within a reactive stream without changing its structure?Multiple choiceMedium
- When considering WebFlux for an e-commerce server, what is a primary benefit over traditional Spring MVC?Multiple choiceMedium
- How would you explain a key difference between using WebFlux and Virtual Threads for handling concurrency in an interview?Multiple choiceMedium