Closed LostKobrakai closed 1 year ago
Reading up on this it seems there are two ways to encode blocks for arrays. They can either start with a positive long
encoded integer stating the number of array items in the block, or it can start with a negative long
encoded integer stating the negated number of array items in the block followed by another long
encoded integer stating the bytesize of the whole block. erlavro
defaults to the latter option: https://github.com/klarna/erlavro/blob/master/src/avro_binary_encoder.erl#L150-L151
The difference seems to be in the first few bytes.
I want to call out that this might also be an issue with avrora, but we're considering switching and I ran a chunk of our existing data against avro_ex to see what breaks.