Package org.springframework.web.reactive
Interface DispatchExceptionHandler
- All Known Implementing Classes:
 RequestMappingHandlerAdapter
public interface DispatchExceptionHandler
Contract to map a 
Throwable to a HandlerResult.
 Supported by DispatcherHandler when used in the following ways:
 
- Set on a 
HandlerResult, allowing aHandlerAdapterto apply its exception handling to deferred exceptions from asynchronous return values, and to response rendering. - Implemented by a 
HandlerAdapterin order to handle exceptions that occur before a request is mapped to a handler. 
- Since:
 - 6.0
 - Author:
 - Rossen Stoyanchev
 - See Also:
 
- 
Method Summary
Modifier and TypeMethodDescriptionreactor.core.publisher.Mono<HandlerResult>handleError(ServerWebExchange exchange, Throwable ex) Handle the given exception, mapping it to aHandlerResultthat can then be used to render an HTTP response. 
- 
Method Details
- 
handleError
Handle the given exception, mapping it to aHandlerResultthat can then be used to render an HTTP response.- Parameters:
 exchange- the current exchangeex- the exception to handle- Returns:
 - a 
Monothat emits aHandlerResultor an error signal with the original exception if it remains not handled 
 
 -