Security experts gave me the hint to avoid returning internal structures in case of any errors. If for example an invalid date format is given, only the 400 error should be sent back to the caller but no detailed message:
"timestamp": "2024-05-25T06:08:37.483+00:00", "status": 400, "error": "Bad Request", "message": "Failed to convert value of type 'java.lang.String' to required type 'java.time.LocalDate'; Failed to convert from type [java.lang.String] to type [@org.springframework.web.bind.annotation.PathVariable @org.springframework.format.annotation.DateTimeFormat java.time.LocalDate] for value [xxxx]", "path": "/test/xxxx"
Is there a way to configure this in spring boot?