-
Notifications
You must be signed in to change notification settings - Fork 123
Closed
Labels
proposalNew external API or other notable changesNew external API or other notable changes
Description
The performance of official encoding/json
. The saying that "official json is slow" is out-of-day. Besides, json-iterator use some low-level packages those may panic when the major version of go advances.
Json-iterator panic issues:
Json-iterator performance issues:
- JSON-ITERATOR 使用要注意的大坑: "在使用json-iterator的过程中,没有发现有json-iterator有内存泄露问题,可以放心使用,但在Go1.10以后性能与标准库差异不大,这个第三方库的意义已经不大了"
- Go 语言原生的 json 包有什么问题?如何更好地处理 JSON 数据?: "jsoniter 并没有什么明显优势。即便是 jsoniter 作为卖点的大数据量解析,优势也是微乎其微"
- Go总结(二一)| JSON编解码: "用json-iterator意义不大,还是用标准库吧,真要提高性能,再想想别的办法,或者研究一下上面恐怖的sonic"
- 有篇文章说“在Go1.10以后性能与标准库差异不大,这个第三方库的意义已经不大了”,是真的吗?有大佬说一下吗?
If you really have performance concern, please use sonic, NOT json-iterator. If not, choose the official one.
Besides, less dependency, less safety issues.
Metadata
Metadata
Assignees
Labels
proposalNew external API or other notable changesNew external API or other notable changes