[
https://issues.apache.org/jira/browse/LOG4J2-33?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13883628#comment-13883628
]
Gary Gregory commented on LOG4J2-33:
------------------------------------
What I do not like about the patch is that it creates a stack trace for every
single logging call. And the usual pattern makes x2 worse:
if (Log.get().isDebugEnabled()) {
Log.get().debug(...);
}
So I would want to say:
Logger logger = Log.get();
if (logger.isDebugEnabled()) {
logger.debug(...);
}
Which is not pretty. Which make me want to save the Logger in an ivar, and
that's the same as having a wrapper.
Am I missing something?
> Support Annotations
> -------------------
>
> Key: LOG4J2-33
> URL: https://issues.apache.org/jira/browse/LOG4J2-33
> Project: Log4j 2
> Issue Type: New Feature
> Components: API
> Reporter: Ralph Goers
> Fix For: 0.1
>
> Attachments: 0001-Add-Loggable.patch
>
>
> The Log4j API should support using annotations as provided in Java 6 so
> applications can use them instead of calls to logger APIs. This is especially
> useful for entering & exiting type of events, but could be used wherever
> annotations are allowed.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]