Is it valid to do something like this:
@RequestMapping(method = RequestMethod.POST)
public @ResponseBody Post doSomething(@PathVariable postId) {
}
@ExceptionHandler(Exception.class)
private ModelAndView handleException(Exception ex, @PathVariable postId) {
}
Looks like Spring is ignoring my exception handler when I add an @PathVariable to its method signature.
IMO that kind of information should be contained within the exception itself anyway.
I’m not aware that exception handlers get path variables.