Top Description Constructors Methods
org.springframework.web.reactive.handler

public Class WebFluxResponseStatusExceptionHandler

extends ResponseStatusExceptionHandler
Class Inheritance
Imports
org.springframework.core.annotation.AnnotatedElementUtils, org.springframework.http.HttpStatusCode, org.springframework.web.bind.annotation.ResponseStatus, org.springframework.web.server.handler.ResponseStatusExceptionHandler

Common WebFlux exception handler that detects instances of org.springframework.web.server.ResponseStatusException (inherited from the base class) as well as exceptions annotated with @ResponseStatus by determining the HTTP status for them and updating the status of the response accordingly.

If the response is already committed, the error remains unresolved and is propagated.

Authors
Juergen Hoeller, Rossen Stoyanchev
Since
5.0.5

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
protected HttpStatusCode
determineStatus(Throwable
the exception to check
ex
)

Overrides org.springframework.web.server.handler.ResponseStatusExceptionHandler.determineStatus.

Determine the HTTP status for the given exception.

Inherited from org.springframework.web.server.handler.ResponseStatusExceptionHandler:
determineRawStatusCodehandlesetWarnLogCategory

Constructor Detail

WebFluxResponseStatusExceptionHandlerback to summary
public WebFluxResponseStatusExceptionHandler()

Method Detail

determineStatusback to summary
protected HttpStatusCode determineStatus(Throwable ex)

Overrides org.springframework.web.server.handler.ResponseStatusExceptionHandler.determineStatus.

Doc from org.springframework.web.server.handler.ResponseStatusExceptionHandler.determineStatus.

Determine the HTTP status for the given exception.

Parameters
ex:Throwable

the exception to check

Returns:HttpStatusCode

the associated HTTP status code, or null if it can't be derived

Annotations
@Override