Class ErrorResponseException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.springframework.core.NestedRuntimeException
org.springframework.web.ErrorResponseException
All Implemented Interfaces:
Serializable, ErrorResponse
Direct Known Subclasses:
ResponseStatusException

public class ErrorResponseException extends org.springframework.core.NestedRuntimeException implements ErrorResponse
RuntimeException that implements ErrorResponse to expose an HTTP status, response headers, and a body formatted as an RFC 9457 ProblemDetail.

The exception can be used as is, or it can be extended as a more specific exception that populates the type or detail fields, or potentially adds other non-standard properties.

Since:
6.0
Author:
Rossen Stoyanchev
See Also: