slfan1989 opened a new pull request, #10271: URL: https://github.com/apache/ozone/pull/10271
## What changes were proposed in this pull request? This PR validates persisted DiskBalancer configuration before applying it to the running service. DiskBalancerService loads persisted configuration from diskbalancer.info and applies it through applyDiskBalancerInfo. Previously, only containerStates was explicitly validated in this path, while other fields such as threshold, bandwidthInMB, and parallelThread were applied directly from DiskBalancerInfo. This PR updates applyDiskBalancerInfo to convert DiskBalancerInfo through DiskBalancerConfiguration, so the existing validation logic is reused consistently before updating the service state. It also adds unit test coverage to verify that invalid persisted DiskBalancer configuration is rejected, including: - invalid threshold - invalid bandwidth - invalid parallel thread count ## What is the link to the Apache JIRA JIRA: HDDS-15278. DiskBalancer should validate persisted config before applying. ## How was this patch tested? Add Some Junit Test. -- 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]
