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 2da50988d [core] Add comments in
DeletionVectorIndexFileWriter.emptyIndexFile
2da50988d is described below
commit 2da50988d47e4527b4de86222ba21ec653fa6b43
Author: Jingsong <[email protected]>
AuthorDate: Thu May 30 16:31:06 2024 +0800
[core] Add comments in DeletionVectorIndexFileWriter.emptyIndexFile
---
.../paimon/deletionvectors/DeletionVectorIndexFileWriter.java | 7 +++++++
1 file changed, 7 insertions(+)
diff --git
a/paimon-core/src/main/java/org/apache/paimon/deletionvectors/DeletionVectorIndexFileWriter.java
b/paimon-core/src/main/java/org/apache/paimon/deletionvectors/DeletionVectorIndexFileWriter.java
index f7fa7eb08..4dddd6ba1 100644
---
a/paimon-core/src/main/java/org/apache/paimon/deletionvectors/DeletionVectorIndexFileWriter.java
+++
b/paimon-core/src/main/java/org/apache/paimon/deletionvectors/DeletionVectorIndexFileWriter.java
@@ -84,6 +84,13 @@ public class DeletionVectorIndexFileWriter {
return writer.writtenIndexFile();
}
+ /**
+ * The deletion file of the bucketed table is updated according to the
bucket. If a compaction
+ * occurs and there is no longer a deletion file, an empty deletion file
needs to be generated
+ * to overwrite the old file.
+ *
+ * <p>TODO: We can consider sending a message to delete the deletion file
in the future.
+ */
private List<IndexFileMeta> emptyIndexFile() throws IOException {
try (SingleIndexFileWriter writer = new SingleIndexFileWriter()) {
return Collections.singletonList(writer.writtenIndexFile());