Skip to content

feat!: resolve schema(ta) in the builder of Writer - #328

Merged
Kriskras99 merged 1 commit into
apache:mainfrom
Kriskras99:feat/builder_resolved_schema
Oct 30, 2025
Merged

Kriskras99 merged 1 commit into
apache:mainfrom
Kriskras99:feat/builder_resolved_schema

Conversation

@Kriskras99

Copy link
Copy Markdown
Contributor

This moves the resolving error to the place where it should happen and simplifies Writer functions.

This is a breaking change, as the builder now returns a AvroResult.

The actual relevant code is in the first 400 lines of avro/src/writer.rs. All other changes are adding ? or .unwrap() to test code.

@Kriskras99
Kriskras99 force-pushed the feat/builder_resolved_schema branch from 6bb5404 to b207de1 Compare October 29, 2025 21:26
This moves the resolving error to the place where it should happen
and simplifies `Writer` functions.

This is a breaking change, as the builder now returns a `AvroResult`.

The actual relevant code is in the first 400 lines of `avro/src/writer.rs`.
All other changes are adding `?` or `.unwrap()` to test code.
@Kriskras99
Kriskras99 force-pushed the feat/builder_resolved_schema branch from b207de1 to b10ed9a Compare October 29, 2025 21:27
Comment thread avro/src/writer.rs Resolved
Comment thread avro/tests/shared.rs Resolved

@martin-g martin-g left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Is Codec really a Copy ?
Some of the codecs have Settings? Don't they allocate heap memory ?

@Kriskras99

Copy link
Copy Markdown
Contributor Author

It really is: https://docs.rs/apache-avro/latest/apache_avro/enum.Codec.html

All of the settings are Copy too. All of them are just the compression level and that's an integer in all compressors we have.

@Kriskras99
Kriskras99 merged commit 0683bae into apache:main Oct 30, 2025
@Kriskras99 Kriskras99 mentioned this pull request Jun 28, 2026
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