Skip to content

Conversation

@aokolnychyi
Copy link
Contributor

After the support for adding data files that belong to multiple specs in #9860, we have to fix resetting hasNewDataFile.

@github-actions github-actions bot added the core label Sep 6, 2024
writer.close();
}
this.cachedNewDataManifests.addAll(writer.toManifestFiles());
this.hasNewDataFiles = false;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think it caused issues but it would be more correct to set hasNewDataFiles to false after processing all new data files, similarly to what we do for delete files. Otherwise, it is confusing.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah agreed, this change is easier to read. Also agree that setting it to false prematurely shouldn't have caused issues, looking at how hasNewDataFiles is used

writer.close();
}
this.cachedNewDataManifests.addAll(writer.toManifestFiles());
this.hasNewDataFiles = false;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah agreed, this change is easier to read. Also agree that setting it to false prematurely shouldn't have caused issues, looking at how hasNewDataFiles is used

@aokolnychyi aokolnychyi merged commit 6e05ae0 into apache:main Sep 7, 2024
@aokolnychyi
Copy link
Contributor Author

Thanks, @amogh-jahagirdar!

zachdisc pushed a commit to zachdisc/iceberg that referenced this pull request Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants