swamirishi commented on code in PR #9656:
URL: https://github.com/apache/ozone/pull/9656#discussion_r3189242674


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/SnapshotDeletingService.java:
##########
@@ -247,39 +248,180 @@ private void submitSnapshotPurgeRequest(List<String> 
purgeSnapshotKeys) {
       }
     }
 
-    private void submitSnapshotMoveDeletedKeys(SnapshotInfo snapInfo,
-                                               List<SnapshotMoveKeyInfos> 
deletedKeys,
-                                               List<HddsProtos.KeyValue> 
renamedList,
-                                               List<SnapshotMoveKeyInfos> 
dirsToMove) {
-
-      SnapshotMoveTableKeysRequest.Builder moveDeletedKeysBuilder = 
SnapshotMoveTableKeysRequest.newBuilder()
+    /**
+     * Submits a single batch of snapshot move requests.
+     *
+     * @param snapInfo The snapshot being processed
+     * @param deletedKeys List of deleted keys to move
+     * @param renamedList List of renamed keys
+     * @param dirsToMove List of deleted directories to move
+     * @return true if submission was successful, false otherwise
+     */
+    private boolean submitSingleSnapshotMoveBatch(SnapshotInfo snapInfo,
+                                                   List<SnapshotMoveKeyInfos> 
deletedKeys,
+                                                   List<HddsProtos.KeyValue> 
renamedList,
+                                                   List<SnapshotMoveKeyInfos> 
dirsToMove) {
+      SnapshotMoveTableKeysRequest.Builder moveDeletedKeys = 
SnapshotMoveTableKeysRequest.newBuilder()
           .setFromSnapshotID(toProtobuf(snapInfo.getSnapshotId()));
 
-      SnapshotMoveTableKeysRequest moveDeletedKeys = moveDeletedKeysBuilder
-          .addAllDeletedKeys(deletedKeys)
-          .addAllRenamedKeys(renamedList)
-          .addAllDeletedDirs(dirsToMove)
-          .build();
-      if (isBufferLimitCrossed(ratisByteLimit, 0, 
moveDeletedKeys.getSerializedSize())) {

Review Comment:
   @aswinshakil this is for the last loop scenario where the moveKeys request 
is much more larger than because the deleteOmKeyInfo is huge. This if block is 
to fallback to min number of keys per snapshot value in such a event. By 
removing this value we are skipping the fallback logic altogether. Did we hit 
some issue with this by any chance?



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