jt2594838 commented on code in PR #13878:
URL: https://github.com/apache/iotdb/pull/13878#discussion_r1843199292


##########
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/compaction/execute/task/InnerSpaceCompactionTask.java:
##########
@@ -196,8 +197,27 @@ protected void 
setTargetFileForRecover(List<TsFileResource> resources) {
     }
   }
 
+  protected void prepareCompactionModFiles() throws IOException {
+    if (!TsFileResource.useSharedModFile) {
+      return;
+    }
+    TsFileResource firstSource = filesView.sourceFilesInLog.get(0);
+    TsFileResource firstTarget = filesView.targetFilesInPerformer.get(0);
+    ModFileManagement modFileManagement = firstSource.getModFileManagement();
+    ModificationFile modificationFile = 
modFileManagement.allocateFor(firstTarget);

Review Comment:
   I think if the resource file is not serialized, then the compaction is not 
completed, and the target file will be removed eventually. 
   So, it does not matter whether the shared mod file can be found in the 
recovery.



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

Reply via email to