You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by il...@apache.org on 2018/04/09 11:33:35 UTC

[incubator-dubbo] branch master updated: remove the method with the same function but the different name in NetUtils (#1572)

This is an automated email from the ASF dual-hosted git repository.

iluo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo.git


The following commit(s) were added to refs/heads/master by this push:
     new 9f48d8d  remove the method with the same function but the different name in NetUtils (#1572)
9f48d8d is described below

commit 9f48d8dbdd06e60faf84809a19a8c4e47733c38d
Author: 时无两丶 <44...@qq.com>
AuthorDate: Mon Apr 9 19:33:32 2018 +0800

    remove the method with the same function but the different name in NetUtils (#1572)
---
 .../java/com/alibaba/dubbo/common/logger/support/FailsafeLogger.java | 2 +-
 .../src/main/java/com/alibaba/dubbo/common/utils/NetUtils.java       | 5 -----
 2 files changed, 1 insertion(+), 6 deletions(-)

diff --git a/dubbo-common/src/main/java/com/alibaba/dubbo/common/logger/support/FailsafeLogger.java b/dubbo-common/src/main/java/com/alibaba/dubbo/common/logger/support/FailsafeLogger.java
index 858a4e0..b964693 100644
--- a/dubbo-common/src/main/java/com/alibaba/dubbo/common/logger/support/FailsafeLogger.java
+++ b/dubbo-common/src/main/java/com/alibaba/dubbo/common/logger/support/FailsafeLogger.java
@@ -37,7 +37,7 @@ public class FailsafeLogger implements Logger {
     }
 
     private String appendContextMessage(String msg) {
-        return " [DUBBO] " + msg + ", dubbo version: " + Version.getVersion() + ", current host: " + NetUtils.getLogHost();
+        return " [DUBBO] " + msg + ", dubbo version: " + Version.getVersion() + ", current host: " + NetUtils.getLocalHost();
     }
 
     public void trace(String msg, Throwable e) {
diff --git a/dubbo-common/src/main/java/com/alibaba/dubbo/common/utils/NetUtils.java b/dubbo-common/src/main/java/com/alibaba/dubbo/common/utils/NetUtils.java
index 5295831..ee79de4 100644
--- a/dubbo-common/src/main/java/com/alibaba/dubbo/common/utils/NetUtils.java
+++ b/dubbo-common/src/main/java/com/alibaba/dubbo/common/utils/NetUtils.java
@@ -182,11 +182,6 @@ public class NetUtils {
         return localAddress;
     }
 
-    public static String getLogHost() {
-        InetAddress address = getLocalAddress();
-        return address == null ? LOCALHOST : address.getHostAddress();
-    }
-
     private static InetAddress getLocalAddress0() {
         InetAddress localAddress = null;
         try {

-- 
To stop receiving notification emails like this one, please contact
iluo@apache.org.