shuan1026 commented on code in PR #11503:
URL: https://github.com/apache/ozone/pull/11503#discussion_r4303388634


##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/diskbalancer/DiskBalancerConfiguration.java:
##########
@@ -169,6 +181,28 @@ public DiskBalancerConfiguration(Double threshold,
   public DiskBalancerConfiguration() {
   }
 
+  @PostConstruct
+  public void validate() {
+    if (threshold <= 0d || threshold >= 100d) {

Review Comment:
   Thanks for the review @slfan1989! 
   Done, NaN is now rejected in both `validate()` and `setThreshold()`, with 
tests added.



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