This is an automated email from the ASF dual-hosted git repository.
lzljs3620320 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/paimon.git
The following commit(s) were added to refs/heads/master by this push:
new 983c78e3d [core] Fix OrphanFilesClean has a chance to delete normal
file (#3075)
983c78e3d is described below
commit 983c78e3dc4694407ffbe55bc63b9aef125caecb
Author: 吴祥平 <[email protected]>
AuthorDate: Wed Mar 27 12:11:55 2024 +0800
[core] Fix OrphanFilesClean has a chance to delete normal file (#3075)
---
.../src/main/java/org/apache/paimon/operation/OrphanFilesClean.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
a/paimon-core/src/main/java/org/apache/paimon/operation/OrphanFilesClean.java
b/paimon-core/src/main/java/org/apache/paimon/operation/OrphanFilesClean.java
index 8d85024cf..13ae240b6 100644
---
a/paimon-core/src/main/java/org/apache/paimon/operation/OrphanFilesClean.java
+++
b/paimon-core/src/main/java/org/apache/paimon/operation/OrphanFilesClean.java
@@ -125,8 +125,8 @@ public class OrphanFilesClean {
nonSnapshotFiles.forEach(this::deleteFileOrDirQuietly);
deletedFilesNum += nonSnapshotFiles.size();
- Set<String> usedFiles = getUsedFiles();
Map<String, Path> candidates = getCandidateDeletingFiles();
+ Set<String> usedFiles = getUsedFiles();
Set<String> deleted = new HashSet<>(candidates.keySet());
deleted.removeAll(usedFiles);