JacksonYao287 commented on a change in pull request #2278:
URL: https://github.com/apache/ozone/pull/2278#discussion_r650399462



##########
File path: 
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/server/SCMClientProtocolServer.java
##########
@@ -675,17 +676,21 @@ public boolean startContainerBalancer(double threshold, 
int idleiterations,
     AUDIT.logWriteSuccess(buildAuditMessageForSuccess(
         SCMAction.START_CONTAINER_BALANCER, null));
     ContainerBalancerConfiguration cbc = new ContainerBalancerConfiguration();
+
     if (threshold > 0) {
       cbc.setThreshold(threshold);
     }
     if (maxDatanodesToBalance > 0) {
       cbc.setMaxDatanodesToBalance(maxDatanodesToBalance);
     }
     if (maxSizeToMove > 0) {
-      cbc.setMaxSizeToMove(maxSizeToMove);
+      cbc.setMaxSizeToMove(maxSizeToMove * OzoneConsts.GB);

Review comment:
       yea, this sounds good, will update this

##########
File path: 
hadoop-hdds/tools/src/main/java/org/apache/hadoop/hdds/scm/cli/ContainerBalancerStartSubcommand.java
##########
@@ -39,7 +39,12 @@
   private double threshold;
 
   @Option(names = {"-i", "--idleiterations"},
-      description = "Maximum consecutive idle iterations")
+      description = "Maximum consecutive idle iterations",
+      //idleiteration could be as follows:
+      // 0 : indicate running infinitely
+      // positive number : indicate the specific iterations
+      // -1 : user does not set this value
+      defaultValue = "-1")

Review comment:
       yes , this seems better , will change this




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



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

Reply via email to