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

adoroszlai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ozone.git


The following commit(s) were added to refs/heads/master by this push:
     new bab281cf0e HDDS-10814. Log exception stack trace in addSCM only at 
debug level (#6642)
bab281cf0e is described below

commit bab281cf0e3b23d4dd3520a06061f7e07ee96ca5
Author: Tejaskriya <[email protected]>
AuthorDate: Wed May 8 15:38:23 2024 +0530

    HDDS-10814. Log exception stack trace in addSCM only at debug level (#6642)
---
 .../java/org/apache/hadoop/hdds/scm/ha/SCMRatisServerImpl.java   | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git 
a/hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/ha/SCMRatisServerImpl.java
 
b/hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/ha/SCMRatisServerImpl.java
index 5c97cff092..70dffba27e 100644
--- 
a/hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/ha/SCMRatisServerImpl.java
+++ 
b/hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/ha/SCMRatisServerImpl.java
@@ -230,9 +230,7 @@ public class SCMRatisServerImpl implements SCMRatisServer {
     final RaftClientReply raftClientReply =
         server.submitClientRequestAsync(raftClientRequest)
             .get(requestTimeout, TimeUnit.MILLISECONDS);
-    if (LOG.isDebugEnabled()) {
-      LOG.info("request {} Reply {}", raftClientRequest, raftClientReply);
-    }
+    LOG.debug("request {} Reply {}", raftClientRequest, raftClientReply);
     return SCMRatisResponse.decode(raftClientReply);
   }
 
@@ -335,8 +333,9 @@ public class SCMRatisServerImpl implements SCMRatisServer {
       }
       return raftClientReply.isSuccess();
     } catch (IOException e) {
-      LOG.error("Failed to update Ratis configuration and add new peer. " +
-          "Cannot add new SCM: {}.", scm.getScmId(), e);
+      LOG.warn("Failed to update Ratis configuration and add new peer. " +
+          "Cannot add new SCM: {}. {}", scm.getScmId(), e.getMessage());
+      LOG.debug("addSCM call failed due to: ", e);
       throw e;
     }
   }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to