Gargi-jais11 commented on code in PR #8297:
URL: https://github.com/apache/ozone/pull/8297#discussion_r2057548160


##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/diskbalancer/DiskBalancerService.java:
##########
@@ -346,8 +351,7 @@ public BackgroundTaskQueue getTasks() {
         inProgressContainers.add(toBalanceContainer.getContainerID());
         deltaSizes.put(sourceVolume, deltaSizes.getOrDefault(sourceVolume, 0L)
             - toBalanceContainer.getBytesUsed());
-        deltaSizes.put(destVolume, deltaSizes.getOrDefault(destVolume, 0L)

Review Comment:
   We're using deltaSizes to reflect space expected to be freed on the source 
volume (though not yet deleted), and committedBytes to reflect space already 
reserved on the destination volume (e.g., due to pending container moves). This 
ensures chooseVolume() to consider both volume committedBytes and deltaSize , 
one for destVolume and one for srcVolume.



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