Exceptions thrown from @ExceptionHandler methods logged at warn level (instead of debug)

Issue: SPR-14861
(cherry picked from commit 7627c38)
This commit is contained in:
Juergen Hoeller
2016-10-30 21:40:20 +01:00
parent 144f687ee9
commit 7e80d2de79

View File

@@ -381,9 +381,9 @@ public class ExceptionHandlerExceptionResolver extends AbstractHandlerMethodExce
exceptionHandlerMethod.invokeAndHandle(webRequest, mavContainer, exception, handlerMethod);
}
}
catch (Exception invocationEx) {
if (logger.isDebugEnabled()) {
logger.debug("Failed to invoke @ExceptionHandler method: " + exceptionHandlerMethod, invocationEx);
catch (Throwable invocationEx) {
if (logger.isWarnEnabled()) {
logger.warn("Failed to invoke @ExceptionHandler method: " + exceptionHandlerMethod, invocationEx);
}
return null;
}