好的想法是十分钱一打,真正无价的是能够实现这些想法的人。

XContentType.SMILE与XContentType.JSON的区别?

Elasticsearch | 作者 Douglas Lee | 发布于2018年02月14日 | 阅读数:7662

IndexResponse response = client.prepareIndex(getIndex().name(), getType().name())
.setSource(JSONUtil.toJSON(e), XContentType.SMILE).get();
 
SMILE : The jackson based smile binary format. Fast and compact binary format.
JSON:A JSON based content type.
 
请问在文档索引的时候XContentType应该选JSON还是SMILE,看了解释也不是很理解 这两个有什么区别?
已邀请:

要回复问题请先登录注册