sadanand48 commented on code in PR #8678:
URL: https://github.com/apache/ozone/pull/8678#discussion_r2193043268


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OMDBCheckpointServletInodeBasedXfer.java:
##########
@@ -255,6 +257,21 @@ public void writeDbDataToStream(HttpServletRequest 
request, OutputStream destina
               hardLinkFileMap, getCompactionLogDir());
           writeDBToArchive(sstFilesToExclude, tmpSstBackupDir, 
maxTotalSstSize, archiveOutputStream, tmpdir,
               hardLinkFileMap, getSstBackupDir());
+

Review Comment:
   Extracting the entire part will result in a method with over 8-10 arguments. 
extracted only the snapshot transfer part.



##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/ozone/om/TestOMDbCheckpointServletInodeBasedXfer.java:
##########
@@ -278,13 +276,146 @@ void testContentsOfTarballWithSnapshot() throws 
Exception {
     assertFalse(hardlinkFilePath.toFile().exists());
   }
 
+  @Test

Review Comment:
   done.



##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OmSnapshotManager.java:
##########
@@ -769,6 +770,15 @@ public static String getSnapshotPath(OzoneConfiguration 
conf,
         OM_DB_NAME + checkpointDirName;
   }
 
+  public static String extractSnapshotIDFromCheckpointDirName(String 
snapshotPath) {
+    // Find "om.db-" in the path and return whatever comes after
+    int index = snapshotPath.lastIndexOf(OM_DB_NAME);
+    if (index == -1 || index + OM_DB_NAME.length() >= snapshotPath.length()) {

Review Comment:
   done.



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