Kryo序列化库:它是否用于生产? [英] Kryo serialization library: is it used in production?

查看:286
本文介绍了Kryo序列化库:它是否用于生产?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Kryo 是一个非常新颖且有趣的Java序列化库,也是 thrift-protobuf 基准。如果你已经使用过Kryo,它已经达到了足够的成熟度,可以在生产代码中试用吗?

Kryo is a very new and interesting Java serialization library, and one of the fastest in the thrift-protobuf benchmark. If you've used Kryo, has it already reached enough maturity to try it out in production code?

更新(10/27/2010):我们正在使用Kryo,虽然尚未投入生产。有关详细信息,请参阅下面的答案。

Update (10/27/2010): We're using Kryo, though not yet in production. See my answer below for details.

更新(2011年3月9日):更新到最新的Jackson和Kryo​​库显示Jackson的二进制文件微笑序列化非常具有竞争力。

Update (3/9/2011): Updating to the latest Jackson and Kryo libraries shows that Jackson's binary Smile serialization is pretty competitive.

推荐答案

有一个错误报告讨论主题。 Kryo附带的DateSerializer在尺寸上比在SO上发布的SimpleSerializer实现稍微有效,因为它使用针对正值优化的LongSerializer。

There is a bug report and a discussion thread. The DateSerializer that comes with Kryo is slightly more efficient size-wise than the SimpleSerializer implementation posted on SO because it uses LongSerializer optimized for positive values.

编辑:我忘了回答原来的问题。我相信Kryo至少用于少数生产系统。本文中提到了它, Jive SBS缓存重新设计:第3部分。在销毁所有人类项目中,Kryo习惯于使用Android手机作为机器人大脑(视频)。

I forgot to answer the original question. I believe Kryo is used in at least a few production systems. There is mention of it in this article, Jive SBS cache redesign: Part 3. In the Destroy All Humans project, Kryo is used to communicate with an Android phone that serves as a robot brain (video here).

不是直接答案,但您可以浏览 Kryo来源和/或 javadocs 。查看Kryo类上的read *和write *方法,然后查看Serializer类。这真的是图书馆的核心。

Not a direct answer, but you might browse the Kryo source and/or javadocs. Check out the read* and write* methods on the Kryo class, then look at the Serializer class. This is really the core of the library.

这篇关于Kryo序列化库:它是否用于生产?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆