Yes, I 100% agree. I would like to do a side project eventually of improving 
avro_derive in the way you suggest (or replacing it with Serde). I just haven't 
gotten around to doing so. But what we have is working for Materialize for now.

> On Feb 17, 2022, at 10:00 PM, Askar Safin <safinas...@mail.ru> wrote:
> 
> > By the way, we have what we believe to be the most correct and complete Rust
> > implementation of Avro here:
> > https://github.com/MaterializeInc/materialize/tree/main/src/avro 
> > <https://github.com/MaterializeInc/materialize/tree/main/src/avro>
> Hi. I spent a lot of time searching for perfect Avro implementation for Rust. 
> And indeed Materialize implementation turned to be the best as I think.
> Still, I rejected it because "avro_derive" doesn't work for Rust enums (with 
> data). I. e. I wanted Rust enums to be converted to Avro
> unions. I rejected other Rust implementations for various reasons, too. So I 
> wrote my own. (I can show code, but note that my implementation is
> incomplete.) Now (because of various Avro problems) I think I will throw away 
> this code and simply will create my own binary format instead.
> 
> I indeed suggest Avro project to base its Rust implementation on 
> Materialize's code, not on "avro-rs" from https://crates.io/crates/avro-rs 
> <https://crates.io/crates/avro-rs> .
> "avro-rs" doesn't even support recursive types. And adding recursive types 
> support will require major rewrite. There is pull request on
> their github for recursive types, but it's still unmerged
> 
> ==
> Askar Safin
> http://safinaskar.com <http://safinaskar.com/>
> https://sr.ht/~safinaskar <https://sr.ht/~safinaskar>
> https://github.com/safinaskar <https://github.com/safinaskar>

Reply via email to