Spring Boot - Debug Webflux reactive application in IDE

With Spring Boot Webflux reactive application, to debug and identify the unexpected exception thrown from a handler while handling http request, put a debug / break point in the following method of the class. This will quickly reveal the exception along with stacktrace with your favourite IDE

Class: org.springframework.web.reactive.DispatcherHandler
Method: handleRequestWith

Have a breakpoint in the line after

Mono<HandlerResult> resultMono = adapter.handle(exchange, handler) 

and evaluate as 

resultMono.block()

Happy Debugging !!!

Comments

Popular posts from this blog

JSON with curl and jq

Import self signed in Linux for Chrome / Chromium headless testing

Colima - Drop In replacement for Docker Desktop for Mac and Linux