hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Attila Bukor (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (HADOOP-13486) Method invocation in log can be replaced by variable because the variable's toString method contain more info
Date Tue, 14 Feb 2017 20:56:41 GMT

     [ https://issues.apache.org/jira/browse/HADOOP-13486?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Attila Bukor resolved HADOOP-13486.
-----------------------------------
    Resolution: Duplicate

> Method invocation in log can be replaced by variable because the variable's toString
method contain more info 
> --------------------------------------------------------------------------------------------------------------
>
>                 Key: HADOOP-13486
>                 URL: https://issues.apache.org/jira/browse/HADOOP-13486
>             Project: Hadoop Common
>          Issue Type: Bug
>    Affects Versions: 2.7.2
>            Reporter: Nemo Chen
>            Assignee: Attila Bukor
>              Labels: easyfix, easytest
>
> Similar to the fix in HADOOP-6419, in file:
> hadoop-rel-release-2.7.2/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/Server.java
> {code}
> Connection c = (Connection)key.attachment();
> ...
> LOG.info(Thread.currentThread().getName() + ": readAndProcess from client " + c.getHostAddress()
+ " threw exception [" + e + "]", (e instanceof WrappedRpcServerException) ? null : e);
> ...
> {code}
> in class Connection, the toString method contains both getHostAddress() and remotePort
> {code}
> public String toString() {
>       return getHostAddress() + ":" + remotePort; 
>     }
> {code}
> Therefore the c.getHostAddress() should be replaced by c for simplicity and information
wise.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org


Mime
View raw message