Golang optimizations for high‑volume services
1 points by pluto
1 points by pluto
The article essentially boils down to:
encoding/json is slow, use something fastersync.Pool to reduce pressure on the GCGiven the title, I expected more in-depth information. It also lacks some interesting details, like which Go version they targeted. If they target Go 1.25 then I'd like to know if they tried encoding/json/v2 and how it performed compared to jsoniter.
All these can be helpful actions, but I wish they'd taken a moment to discuss the profiling that had led them to this. Without that I think other engineers on the internet can too often take a checklist approach where they just slap "solutions" without understanding their problems.
Profiling allocations and cpu (and to a lesser extent mutex contention) often points a giant finger at the sources of allocation.