Affects: Spring Framework 5.2.5.RELEASE
The above mentioned method does not document this: https://github.com/spring-projects/spring-framework/blob/8d31dcaa297c3e9001a6e8470b400641ae1c49d0/spring-web/src/main/java/org/springframework/http/HttpHeaders.java#L1562-L1565
This results in a 500 while it should be a 400 for the client. Either document this fact or use a ResponseStatusException.
Comment From: rstoyanchev
Yes we can document. Normally such low level classes don't throw status exceptions.
Comment From: michael-o
That's fine by me.