Skip to content

Commit

Permalink
Merge branch '3.2.x' into 3.3.x
Browse files Browse the repository at this point in the history
Closes gh-42190
  • Loading branch information
snicoll committed Sep 9, 2024
2 parents 2c9f693 + aef56bc commit 7b6997a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ public void setDateTime(String dateTime) {
public static class Problemdetails {

/**
* Whether RFC 7807 Problem Details support should be enabled.
* Whether RFC 9457 Problem Details support should be enabled.
*/
private boolean enabled = false;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ public enum MatchingStrategy {
public static class Problemdetails {

/**
* Whether RFC 7807 Problem Details support should be enabled.
* Whether RFC 9457 Problem Details support should be enabled.
*/
private boolean enabled = false;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ For machine clients, it produces a JSON response with details of the error, the
For browser clients, there is a "`whitelabel`" error handler that renders the same data in HTML format.
You can also provide your own HTML templates to display errors (see the xref:web/reactive.adoc#web.reactive.webflux.error-handling.error-pages[next section]).

Before customizing error handling in Spring Boot directly, you can leverage the {url-spring-framework-docs}/web/webflux/ann-rest-exceptions.html[RFC 7807 Problem Details] support in Spring WebFlux.
Before customizing error handling in Spring Boot directly, you can leverage the {url-spring-framework-docs}/web/webflux/ann-rest-exceptions.html[RFC 9457 Problem Details] support in Spring WebFlux.
Spring WebFlux can produce custom error messages with the `application/problem+json` media type, like:

[source,json]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ TIP: The `BasicErrorController` can be used as a base class for a custom `ErrorC
This is particularly useful if you want to add a handler for a new content type (the default is to handle `text/html` specifically and provide a fallback for everything else).
To do so, extend `BasicErrorController`, add a public method with a `@RequestMapping` that has a `produces` attribute, and create a bean of your new type.

As of Spring Framework 6.0, {url-spring-framework-docs}/web/webmvc/mvc-ann-rest-exceptions.html[RFC 7807 Problem Details] is supported.
As of Spring Framework 6.0, {url-spring-framework-docs}/web/webmvc/mvc-ann-rest-exceptions.html[RFC 9457 Problem Details] is supported.
Spring MVC can produce custom error messages with the `application/problem+json` media type, like:

[source,json]
Expand Down

0 comments on commit 7b6997a

Please sign in to comment.