Prevent response updates if @ResponseStatus has reason

When @ResponseStatus has a reason and servletResponse.sendError() is
called, the response is committed and should no longer be written to.
After this change, the ServletInvocableHandlerMethod will mark the
response fully handled and will ignore any non-null return values.

Issue: SPR-9159
This commit is contained in:
Rossen Stoyanchev
2012-05-11 17:41:14 -04:00
parent 0b17dd2242
commit d52fc3bd2f
4 changed files with 32 additions and 11 deletions

View File

@@ -14,12 +14,13 @@ Changes in version 3.2 M1
* fix case-sensitivity issue with some containers on access to 'Content-Disposition' header
* add Servlet 3.0 based async support
* fix issue with encoded params in UriComponentsBuilder
* add Jackson 2 HttpMessageConverter and View types
* add HttpMessageConverter and View types compatible with Jackson 2.0
* add pretty print option to Jackson HttpMessageConverter and View types
* fix issue with resolving Errors controller method argument
* detect controller methods via InitializingBean in RequestMappingHandlerMapping
* translate IOException from Jackson to HttpMessageNotReadableException
* fix content negotiation issue when sorting selected media types by quality value
* Prevent further writing to the response when @ResponseStatus contains a reason
Changes in version 3.1.1 (2012-02-16)