Skip to content

Deserializer support for BigDecimal when using apache_avro::serde::bigdecimal#543

Merged
martin-g merged 6 commits into
apache:mainfrom
jdarais:jd-fix-big-decimal-bytes
May 15, 2026
Merged

Deserializer support for BigDecimal when using apache_avro::serde::bigdecimal#543
martin-g merged 6 commits into
apache:mainfrom
jdarais:jd-fix-big-decimal-bytes

Conversation

@jdarais
Copy link
Copy Markdown
Contributor

@jdarais jdarais commented May 12, 2026

It looks like serialization/deserialization was made more strict, and in the process, Deserializer no longer supports deserializing BigDecimal as a string, (which is what BigDecimal serializes/deserializes to/from by default.) That's ok, since you can just add #[serde(with="apache_avro::serde::bigdecimal")], but then it appears that deserializing BigDecimal as bytes is missing. This PR adds the missing support for deserializing BigDecimal as bytes.

Comment thread avro/src/serde/de.rs Outdated
@martin-g martin-g added this to the 0.22.0 milestone May 12, 2026
@martin-g martin-g force-pushed the jd-fix-big-decimal-bytes branch from ee143cb to 551c09b Compare May 12, 2026 12:10
Comment thread avro/src/serde/de.rs Outdated
Comment thread avro/src/serde/de.rs Outdated
Co-authored-by: Martin Grigorov <martin-g@users.noreply.github.com>
@martin-g martin-g merged commit bf83d63 into apache:main May 15, 2026
13 checks passed
@martin-g
Copy link
Copy Markdown
Member

Thank you, @jdarais !

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