MessagePack versus BSON

647 views
Skip to first unread message

Chuck Remes

unread,
Mar 20, 2010, 1:16:15 PM3/20/10
to mongodb-user
While reading through my usual Saturday morning RSS feeds I saw a post about a new data serializer/deserializer called MessagePack [1]. It touts extreme performance and compares itself against ProtocolBuffers and JSON. The Reddit thread discussing it talks about BSON too a little bit.

So I thought I would do a very simple comparison.

ruby-mongo-driver 0.19.1
message pack 0.3.3

I modified the bson_benchmark file that comes with the mongo ruby driver (in the bin dir) to include MessagePack. The code is available at http://gist.github.com/338773 along with the benchmark results from my laptop.

I thought this might be of interest to folks. Additionally, this might be of interest to BSON developers since it appears there might be a little work to do.

cr

[1] http://msgpack.sourceforge.net/

dwight_10gen

unread,
Mar 20, 2010, 2:07:34 PM3/20/10
to mongodb-user
hmmm MessagePack looks kind of interesting. it looks like it is more
focused on tight representation than BSON - BSON is focused on fast
scan ability.

i would say based on the results that the ruby BSON implementation is
suboptimal, we'll take a look -- the implementation is different for
each language.


On Mar 20, 1:16 pm, Chuck Remes <cremes.devl...@mac.com> wrote:
> While reading through my usual Saturday morning RSS feeds I saw a post about a new data serializer/deserializer called MessagePack [1]. It touts extreme performance and compares itself against ProtocolBuffers and JSON. The Reddit thread discussing it talks about BSON too a little bit.
>
> So I thought I would do a very simple comparison.
>
> ruby-mongo-driver 0.19.1
> message pack 0.3.3
>

> I modified the bson_benchmark file that comes with the mongo ruby driver (in the bin dir) to include MessagePack. The code is available athttp://gist.github.com/338773along with the benchmark results from my laptop.

Kyle Banker

unread,
Mar 20, 2010, 2:27:37 PM3/20/10
to mongod...@googlegroups.com
Hi Chuck,

Thanks for posting. We'll definitely shoot for speeding up the Ruby BSON encoder.  Since MessagePack supports Python and Perl, it'd be worthwhile to test against those drivers' BSON encoders as well.

Kyle

--
You received this message because you are subscribed to the Google Groups "mongodb-user" group.
To post to this group, send email to mongod...@googlegroups.com.
To unsubscribe from this group, send email to mongodb-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/mongodb-user?hl=en.


Reply all
Reply to author
Forward
0 new messages