Sitemap
The Ordinary Programmer

The Ordinary Programmer is for coders who embrace simplicity and practicality. We share real-world tips, project stories, and tech insights for developers at every level. You don’t need to be a superstar — just a programmer who loves to learn and build helpful software.

Member-only story

Analyze Various High-Performance JSON Parsing Library In Go.

12 min readJun 16, 2024

--

Press enter or click to view image in full size
Photo by Ferenc Almasi on Unsplash

Compare the performance, advantages, and disadvantages of fastjson, gjson, and jsonparser.

This article delves into the analysis of how the standard library in Go parses JSON and then explores popular JSON parsing libraries, their characteristics, and how they can better assist us in development in different scenarios.

I didn’t plan to investigate the JSON library’s performance issue. However, recently, I did a pprof on my project and found, from the flame graph below, that more than half of the performance consumption in business logic processing is during JSON parsing. Therefore, this article came about.

Press enter or click to view image in full size

This article delves into the analysis of how the standard library in Go parses JSON and then explores popular JSON parsing libraries, their characteristics, and how they can better assist us in development in different scenarios.

Mainly introduce the analysis of the following libraries (2024–06–13):

--

--

The Ordinary Programmer
The Ordinary Programmer

Published in The Ordinary Programmer

The Ordinary Programmer is for coders who embrace simplicity and practicality. We share real-world tips, project stories, and tech insights for developers at every level. You don’t need to be a superstar — just a programmer who loves to learn and build helpful software.

huizhou92
huizhou92

Written by huizhou92

Golang backend engineer. Specializes in cloud, data, and security. Lifelong learner. Efficiency enthusiast.