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 f7fa7eb08722..4dddd6ba162e 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 @@ private IndexFileMeta tryWriter(Iterator> iter 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. + * + *

TODO: We can consider sending a message to delete the deletion file in the future. + */ private List emptyIndexFile() throws IOException { try (SingleIndexFileWriter writer = new SingleIndexFileWriter()) { return Collections.singletonList(writer.writtenIndexFile());