hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bus...@apache.org
Subject [02/27] hbase git commit: HBASE-18470 Remove the redundant comma from RetriesExhaustedWithDetailsException#getDesc
Date Wed, 09 Aug 2017 05:51:18 GMT
HBASE-18470 Remove the redundant comma from RetriesExhaustedWithDetailsException#getDesc

Signed-off-by: Chia-Ping Tsai <chia7712@gmail.com>


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/fe890b70
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/fe890b70
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/fe890b70

Branch: refs/heads/HBASE-18467
Commit: fe890b70ace30f35cce947de26a64fb646290219
Parents: 855dd48
Author: Benedict Jin <1571805553@qq.com>
Authored: Thu Aug 3 14:55:23 2017 +0800
Committer: Chia-Ping Tsai <chia7712@gmail.com>
Committed: Thu Aug 3 15:42:53 2017 +0800

----------------------------------------------------------------------
 .../hbase/client/RetriesExhaustedWithDetailsException.java       | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/fe890b70/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RetriesExhaustedWithDetailsException.java
----------------------------------------------------------------------
diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RetriesExhaustedWithDetailsException.java
b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RetriesExhaustedWithDetailsException.java
index 70d5548..e1a6754 100644
--- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RetriesExhaustedWithDetailsException.java
+++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RetriesExhaustedWithDetailsException.java
@@ -111,10 +111,10 @@ extends RetriesExhaustedException {
     Set<String> uniqAddr = new HashSet<>();
     uniqAddr.addAll(hostnamePort);
 
-    for(String addr : uniqAddr) {
+    for (String addr : uniqAddr) {
       addrs.append(addr).append(", ");
     }
-    return addrs.toString();
+    return uniqAddr.isEmpty() ? addrs.toString() : addrs.substring(0, addrs.length() - 2);
   }
 
   public String getExhaustiveDescription() {


Mime
View raw message