Specific exceptions for missing request headers, cookies, etc [SPR-14818] #19384
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
type: enhancement
A general enhancement
Milestone
Austin Song opened SPR-14818 and commented
When a parameter annotated with
@RequestHeader
and has required = true, a ServletBindingException is thrown when it is missing from the incoming request. This exception appears to be able to be thrown from multiple places. A more specific exception such as a MissingServletRequestHeader exception makes sense here to be consistent with parameters (i.e. MissingServletRequestParameter exception).Issue Links:
Referenced from: pull request #1653
2 votes, 5 watchers
The text was updated successfully, but these errors were encountered: