Repository navigation
feat(spark): let VortexOutputWriter store footer metadata - #11137
robert3005 merged 2 commits into
Conversation
Adds a VortexOutputWriter constructor that takes footer metadata segments and passes them to the JNI writer builder, so callers writing files outside Spark's commit protocol can record their own metadata without a custom writer. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Christopher Wirt <cwirt@quantcast.com>
Head branch was pushed to by a user without write access
9d6f4c8 to
5e30b68
Compare
Merging this PR will degrade performance by 11.13%2 warnings
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing Footnotes
|
Summary
VortexWriter.Buildercan store user metadata segments in the file footer, butVortexOutputWriterdoesn't expose this. A caller writing files from Spark outside the commit protocol has to keep its own copy of the writer just to set footer keys.This adds a
VortexOutputWriterconstructor that takes footer metadata.Changes
VortexOutputWriter(filePath, schema, options, writable, metadata), which passesmetadatatoVortexWriter.Builder.metadata.Tests
VortexOutputWriterTest.storesFooterMetadatawrites a file with one metadata key and reads it back withNativeFiles.readMetadata.On the fork (quantcast#77, same change), the Java changes are the same.
develop'sVortexOutputWriterdiffers around the builder call, so this branch reapplies the change by hand. Onlygit diff --checkhas been run on the port.API Changes
VortexOutputWriterconstructor takingMap<String, byte[]> metadata. Existing callers are unaffected.AI assistance
Disclosed per the AI policy: AI tools helped write and review this change. Claude Code prepared this upstream port, issue and PR description at my request. I am the responsible contributor.
🤖 Generated with Claude Code