hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tsuyoshi Ozawa (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-11741) Add LOG.isDebugEnabled() guard for some LOG.debug(..)
Date Tue, 24 Mar 2015 16:17:53 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-11741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14378082#comment-14378082
] 

Tsuyoshi Ozawa commented on HADOOP-11741:
-----------------------------------------

[~walter.k.su] thank you for taking this issue. LGTM overall. One minor nits: There is a line
here that exceed 80 characters. Could you fix it?
{code}
       LOG.debug("RpcKind = " + rpcKind + " Protocol Name = " + protocolName + " version="
+ version +
{code}



> Add LOG.isDebugEnabled() guard for some LOG.debug(..)
> -----------------------------------------------------
>
>                 Key: HADOOP-11741
>                 URL: https://issues.apache.org/jira/browse/HADOOP-11741
>             Project: Hadoop Common
>          Issue Type: Improvement
>            Reporter: Walter Su
>            Assignee: Walter Su
>         Attachments: HADOOP-11741.001.patch
>
>
> {{isDebugEnabled()}} is optional. But when there are :
> 1. lots of concatenating Strings
> 2. complicated function calls
> in the arguments, {{LOG.debug(..)}} should be guarded with {{LOG.isDebugEnabled()}} to
avoid unnecessary arguments evaluation and impove performance.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message