Loading tutorials
/error response from the previous chapter. Here you will change what that default response contains by setting server.error.* properties.2 min readthrow in your controller and the HTTP response the client receives.3 min readProblemDetail is. It also assumes you have a custom exception such as OrderNotFoundException, which carries the missing order id.2 min read@ExceptionHandler method. Here you move those handlers into one class that covers every controller.3 min read@RestControllerAdvice from the previous chapter. Here you will standardize the JSON that your handlers return.2 min read@RestControllerAdvice and ProblemDetail. You also need spring-boot-starter-validation on the classpath. Without it, the @Valid annotation has no effect.2 min read@RestControllerAdvice like the one from the previous chapters, and that you know SLF4J basics (Logger, log levels). It covers where to log an exception, at which level, and how to avoid logging it twice.2 min read@RestControllerAdvice with @ExceptionHandler methods and return ProblemDetail bodies, as covered earlier. It looks at what those responses can accidentally reveal and how to stop that.3 min readOrderController, OrderNotFoundException and ApiExceptionHandler from the earlier chapters. You should also know basic JUnit 5. The goal is to prove that each failure produces the status code and ProblemDetail body you designed.2 min read@ExceptionHandler, @RestControllerAdvice and ProblemDetail. It also assumes you know the basics of Mono and Flux from Project Reactor. It covers only what changes when you use Spring WebFlux, the reactive web stack, instead of Spri2 min read