adoroszlai commented on a change in pull request #234: HDDS-2531. Sonar : 
remove duplicate string literals in BlockOutputStream
URL: https://github.com/apache/hadoop-ozone/pull/234#discussion_r348308060
 
 

 ##########
 File path: 
hadoop-hdds/client/src/main/java/org/apache/hadoop/hdds/scm/storage/BlockOutputStream.java
 ##########
 @@ -536,9 +530,9 @@ private void setIoException(Exception e) {
           "Unexpected Storage Container Exception: " + e.toString(), e);
       ioException.compareAndSet(null, exception);
     } else {
-      LOG.debug("Previous request had already failed with " + ioe.toString()
+      LOG.debug("Previous request had already failed with {}"
           + " so subsequent request also encounters"
-          + " Storage Container Exception ", e);
+          + " Storage Container Exception ", ioe.toString(), e);
 
 Review comment:
   Avoid eagerly calling `toString()` for log parameters.
   
   ```suggestion
             + " Storage Container Exception ", ioe, e);
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

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

Reply via email to