You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by GitBox <gi...@apache.org> on 2022/06/13 17:44:02 UTC

[GitHub] [ozone] umamaheswararao commented on a diff in pull request #3484: HDDS-6577. Configurations to reserve HDDS volume space.

umamaheswararao commented on code in PR #3484:
URL: https://github.com/apache/ozone/pull/3484#discussion_r895978973


##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/volume/VolumeUsage.java:
##########
@@ -61,6 +61,14 @@ public long getUsedSpace() {
     return source.getUsedSpace();
   }
 
+  public void incrementUsedSpace(long usedSpace) {
+    source.incrementUsedSpace(usedSpace);
+  }
+

Review Comment:
   Variable name should reclaimedSpace or so?



##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/keyvalue/statemachine/background/BlockDeletingService.java:
##########
@@ -489,10 +490,11 @@ public ContainerBackgroundTaskResult deleteViaTransactionStore(
               deletedBlocksCount, releasedBytes);
 
           // update count of pending deletion blocks, block count and used
-          // bytes in in-memory container status.
+          // bytes in in-memory container status and used space in volume.
           containerData.decrPendingDeletionBlocks(deletedBlocksCount);
           containerData.decrBlockCount(deletedBlocksCount);

Review Comment:
   Isn't it a good idea to decrement the space in containerData.decrBytesUsed ?
   So, that increment and decrement will be in same place? 



-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org