Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AVRO-3821: [Rust] Encoding records should follow the schema #2417

Merged
merged 1 commit into from
Aug 4, 2023

Conversation

martin-g
Copy link
Member

@martin-g martin-g commented Aug 4, 2023

AVRO-3821

When encoding Value::Record the logic should use the order of the fields in the schema instead of the order in the Value::Record

What is the purpose of the change

  • Fix the encoding of apache_avro::types::Value::Record which fields are not sorted as the schema fields

Verifying this change

  • A unit test is updated to cover this case

Documentation

  • Does this pull request introduce a new feature? no

When encoding Value::Record the logic should use the order of the fields
in the schema instead of the order in the Value::Record

Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
@github-actions github-actions bot added the Rust label Aug 4, 2023
@martin-g martin-g merged commit d05ca14 into master Aug 4, 2023
14 checks passed
@martin-g martin-g deleted the avro-3821-fix-encoding-of-records branch August 4, 2023 12:40
martin-g added a commit that referenced this pull request Aug 4, 2023
When encoding Value::Record the logic should use the order of the fields
in the schema instead of the order in the Value::Record

Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
(cherry picked from commit d05ca14)
RanbirK pushed a commit to RanbirK/avro that referenced this pull request May 13, 2024
)

When encoding Value::Record the logic should use the order of the fields
in the schema instead of the order in the Value::Record

Signed-off-by: Martin Tzvetanov Grigorov <mgrigorov@apache.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
1 participant