Add required flag to @RequestBody

If true and there is no body => HttpMessageNotReadableException
If false and there is no body, the argument resolves to null.

Issue: SPR-9239
This commit is contained in:
Rossen Stoyanchev
2012-05-17 17:48:48 -04:00
parent 0105c5ebb9
commit 77ae101402
4 changed files with 88 additions and 21 deletions

View File

@@ -28,6 +28,7 @@ Changes in version 3.2 M1
* add ability to configure custom MessageCodesResolver through the MVC Java config
* add option in MappingJacksonJsonView for setting the Content-Length header
* decode path variables when url decoding is turned off in AbstractHandlerMapping
* add required flag to @RequestBody annotation
Changes in version 3.1.1 (2012-02-16)
-------------------------------------