Skip to content

refactor(encryption) remove key_metadata from the constructor of an unencrypted manifest writer#2666

Merged
blackmwk merged 3 commits into
apache:mainfrom
xanderbailey:xb/remove_metadata_from_writer_constructor
Jul 1, 2026
Merged

refactor(encryption) remove key_metadata from the constructor of an unencrypted manifest writer#2666
blackmwk merged 3 commits into
apache:mainfrom
xanderbailey:xb/remove_metadata_from_writer_constructor

Conversation

@xanderbailey

@xanderbailey xanderbailey commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Follow up for #2628

What changes are included in this PR?

Now that we have two constructors for ManifestWriterBuilder, new and new_from_encrypted, it should never be the case that you want to present key_metadata to an unencrypted output.

Are these changes tested?

let builder = ManifestWriterBuilder::new(
output_file,
Some(self.snapshot_id),
self.key_metadata.clone(),

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The metadata here comes from the fast append action which I think is also wrong but I'll remove that in a further follow up PR to keep these refactors targeted.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Ahh metadata becomes dead code on snapshot producer so maybe I will remove here.

@blackmwk blackmwk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks @xanderbailey for this pr, just one minor comment.

Comment thread crates/iceberg/src/spec/manifest/writer.rs
@xanderbailey

Copy link
Copy Markdown
Contributor Author

Thanks for the quick review @blackmwk, can you take another quick look because I've also removed this from FastAppendAction fb5df7e since it was now "dead code"

@xanderbailey

Copy link
Copy Markdown
Contributor Author

@blackmwk I think this should be ready to go if you're happy! Thanks again for the review!

@blackmwk

blackmwk commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Thanks @xanderbailey for this pr!

@blackmwk blackmwk merged commit 1016ace into apache:main Jul 1, 2026
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants