You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "stevenzwu (via GitHub)" <gi...@apache.org> on 2026/02/02 22:44:15 UTC
Re: [PR] Core: Detect and merge duplicate DVs for a data file and merge them before committing [iceberg]
stevenzwu commented on code in PR #15006:
URL: https://github.com/apache/iceberg/pull/15006#discussion_r2756343984
##########
core/src/main/java/org/apache/iceberg/MergingSnapshotProducer.java:
##########
@@ -1060,9 +1062,32 @@ private List<ManifestFile> newDeleteFilesAsManifests() {
}
if (cachedNewDeleteManifests.isEmpty()) {
+ Map<String, List<DeleteFile>> duplicateDVs = Maps.newHashMap();
+ List<DeleteFile> validDVs = Lists.newArrayList();
+ for (Map.Entry<String, List<DeleteFile>> entry : dvsByReferencedFile.entrySet()) {
Review Comment:
it might be a little simpler if we just do one iteration over the `dvsByReferencedFile` map that transforms `Map<String, List<DeleteFile>>` to `Map<String, DeleteFile>`. It is a **stateful** transform function that can create a new puffin file to host the merged DVs.
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org