[infinispan-dev] Avro for basic type marshalling (ISPN-508)

Galder Zamarreño galder at redhat.com
Tue Aug 3 09:17:28 EDT 2010


On Aug 2, 2010, at 5:03 PM, Galder Zamarreño wrote:

> Hi,
> 
> Re: https://jira.jboss.org/browse/ISPN-508
> 
> I've done some little tests with simple data types and you can find the results of my tests in http://spreadsheets.google.com/pub?key=0Ag5RGdzR_GsldDdOVnpwbDUyT20xZlZPZUk5aFNjcGc&hl=en&output=html
> 
> After some consideration, I'm going for Apache Avro for basic type marshalling. It offers the best compromise between small payloads and simple marshaller implementation. I had doubts between Avro and Protobufs, particularly when Protobufs was encoded manually. However, Avro offers a higher level, easier to read and simpler implementation (http://pastebin.mozilla.org/759797) compared to manual Protobufs (http://pastebin.mozilla.org/759800). On top of that, Avro offers support for two extra languages that Protobufs doesn't, which include C and Ruby. Finally, Avro offers same payload sizes as the most efficient encoding for Protobufs.
> 
> Same as Protobufs manual encoding, Avro does not require any precompilation for handling basic type/collections.
> 
> Note that the choice of library at this level does not force users to have to use this library for custom objects, although the library for basic types might not support a language that the tool users choose for custom types, which could be a problem. With Avro, I think we have a fair few languages covered, so I don't forsee this problem in the near future. Users can safely use Protobufs or any other library and the marshaller will just treat it as a normal byte[].
> 
> Thrift and Message Pack are IMO still in their infancy and are not ready for the job. 
> 
> Next up I'll build the full marshaller. At this point, I think it makes sense to have this marshaller in the Hot Rod module.

Actually, I'm talking rubbish here. The marshaller should leave in the Hot Rod client module.

> 
> Cheers,
> --
> Galder Zamarreño
> Sr. Software Engineer
> Infinispan, JBoss Cache
> 
> 
> _______________________________________________
> infinispan-dev mailing list
> infinispan-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/infinispan-dev

--
Galder Zamarreño
Sr. Software Engineer
Infinispan, JBoss Cache




More information about the infinispan-dev mailing list