我写了一个自定义AccessDeniedHandler
(看this答案),它运行正常。但我想知道,为什么AccessDeniedException
仍然记录在后台:
org.springframework.security.access.AccessDeniedException: Zugriff verweigert
at org.springframework.security.access.vote.AffirmativeBased.decide(AffirmativeBased.java:84)
at org.springframework.security.access.intercept.AbstractSecurityInterceptor.beforeInvocation(AbstractSecurityInterceptor.java:233)
如何抑制此日志记录?或者更好:我如何控制,何时记录此消息以及何时不记录?