fastjson2/docs/jsonb_size_compare.md
2023-03-02 19:08:53 +08:00

28 lines
994 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 带类型信息 KeyValue映射
| | size | |
|----------------|------|-----------------------------|
| jsonb | 409 | 使用WriteClassName |
| hessian | 644 | |
| fury | 670 | 配置CompatibleMode.COMPATIBLE |
| java serialize | 1123 | |
# 不带类型信息 KeyValue映射
对象使用KeyValue的方式映射这种方式的好处是增加和删除字段不影响兼容性
| | size | |
|------------|------|---------------|
| json | 451 | |
| jsonb | 348 | |
# 不带类型信息 Array映射
对象使用数组的方式映射,这种方式对增加/删除字段会影响兼容性
| | size | |
|------------|------|---------------|
| json | 276 | 配置BeanToArray |
| jsonb | 223 | 配置BeanToArray |
| protobuf-3 | 235 | |