sadanand48 commented on code in PR #8910:
URL: https://github.com/apache/ozone/pull/8910#discussion_r2256485117


##########
hadoop-ozone/cli-admin/src/main/java/org/apache/hadoop/hdds/scm/cli/ContainerBalancerStartSubcommand.java:
##########
@@ -131,10 +131,12 @@ public void execute(ScmClient scmClient) throws 
IOException {
     if (response.getStart()) {
       System.out.println("Container Balancer started successfully.");
     } else {
-      System.out.println("Failed to start Container Balancer.");
+      String errMsg = "Failed to start Container Balancer.";
+      System.out.println(errMsg);

Review Comment:
   nit :
   ```suggestion
         System.err.println(errMsg);
   ```



##########
hadoop-ozone/cli-admin/src/main/java/org/apache/hadoop/hdds/scm/cli/ContainerBalancerStopSubcommand.java:
##########
@@ -34,7 +34,13 @@ public class ContainerBalancerStopSubcommand extends 
ScmSubcommand {
   @Override
   public void execute(ScmClient scmClient) throws IOException {
     System.out.println("Sending stop command. Waiting for Container Balancer 
to stop...");
-    scmClient.stopContainerBalancer();
-    System.out.println("Container Balancer stopped.");
+    try {
+      scmClient.stopContainerBalancer();
+      System.out.println("Container Balancer stopped.");
+    } catch (IOException e) {
+      String msg = "Failed to stop Container Balancer";
+      System.out.println(msg);

Review Comment:
   same here
   ```suggestion
         System.err.println(msg);
   ```



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to