You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "Volkan Yazici (Jira)" <ji...@apache.org> on 2021/02/23 21:07:00 UTC
[jira] [Resolved] (LOG4J2-3020) Logger.catching(Throwable) does not
document level it is logging at
[ https://issues.apache.org/jira/browse/LOG4J2-3020?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Volkan Yazici resolved LOG4J2-3020.
-----------------------------------
Resolution: Fixed
> Logger.catching(Throwable) does not document level it is logging at
> -------------------------------------------------------------------
>
> Key: LOG4J2-3020
> URL: https://issues.apache.org/jira/browse/LOG4J2-3020
> Project: Log4j 2
> Issue Type: Bug
> Components: Documentation
> Affects Versions: 2.14.0
> Reporter: Marcono1234
> Assignee: Volkan Yazici
> Priority: Major
> Fix For: 3.0.0, 2.14.1
>
>
> The [documentation|https://logging.apache.org/log4j/2.x/log4j-api/apidocs/org/apache/logging/log4j/Logger.html#catching-java.lang.Throwable-] of the method {{Logger.catching(Throwable)}} is not mentioning at which level it is logging at.
> It appears {{AbstractLogger}} is logging at level {{ERROR}}, but without it being explicitly mentioned, I think expecting it to be logged at {{DEBUG}} might also be a reasonable expectation.
> It would therefore be good to explicitly mention the log level in the documentation.
> ----
> As a side note: Personally I think the use case described by the {{catching}} documentation rather sounds like it should be logged at {{DEBUG}}:
> {quote}
> In other cases where simply logging the fact that an exception was swallowed somewhere
> {quote}
> To me that sounds like ignoring exceptions such as timeout exceptions and retrying an operation.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)