On Feb 3, 2014, at 6:24 PM, Galder Zamarreño <galder(a)redhat.com> wrote:
Not sure I understand the need to compare this.
JBMAR and ProtoStream are solving different problems. The former is focused on getting
the best out of Java persistence. The latter is focused on serializing stuff in a
plattform independent way.
IMO, it’s not an apples to apples comparison.
AFAIK the only thing JBMAR does and proto doesn't is tracking circular references:
e.g. person has a reference to address which has a reference to the same person instance.
That comes at a performance cost (I guess an IdentityMapLookup per serialized object),
though and for many users tracking circular dependencies is not needed, because of their
data model. My expectation is that ISPN+protostram will be faster than ISPN+JBMAR
because:
- protostream doesn't track circular references (AFAIK this is something that can be
disabled in JBMAR as well)
- protostream allows for partial deserialization, that is only deserialize a specific
attribute of a class
On top of that, it is platform independent, so if you start using it as the default
serialization format, it will be easier for you to use ISPN from multiple platforms.
The drawback protostream has over JBMAR is that it requires one to define, besides the
serialized, a protofile. Las time we discussed, Adrian had some ideas on how that can be
circumvented, though.
IMO, in certain deployments makes sense to use protostream over JBMAR even when
serializing only java objects and this benchmark would be a good tool to validate that.
Cheers,
--
Mircea Markus
Infinispan lead (
www.infinispan.org)