TouK / nussknacker

Low-code tool for automating actions on real time data | Stream processing for the users.
https://nussknacker.io
Apache License 2.0
644 stars 93 forks source link

Faster serialization of Avro unions #6880

Closed piotrp closed 4 days ago

piotrp commented 4 days ago

Describe your changes

Checklist before merge

github-actions[bot] commented 4 days ago

created: #6882 :warning: Be careful! Snapshot changes are not necessarily the cause of the error. Check the logs.

lciolecki commented 4 days ago

What about encodeRecord? There is also $schema in error.

piotrp commented 4 days ago

I left full schema in places that are likely to be called directly, not as part of a union. In case of records it may be helpful to have a full schema in error message.

This PR is meant as a quick fix to work around the most important inefficiency: handling schemas with nulls (e.g. type: ["null", "string"]). This entire encoder should be rewritten to handle unions efficiently.