Go Developers
func25's profile
Phuong Le@func25•Nov 15, 2025
5.2K
Post cover image

How We Saved 70% of CPU and 60% of Memory in Refinery’s Go Code, No Rust Required

From honeycomb.io•Nov 15, 2025•6m read time

Refinery 3.0 achieved 70% CPU and 60% memory reduction through strategic optimization of Go code. The key improvement was avoiding full deserialization of trace spans by selectively extracting only needed fields from serialized data, keeping the rest in compact MessagePack format. This eliminated thousands of heap allocations per span and reduced garbage collection overhead from 25% to minimal levels. Additional optimizations included direct binary-to-binary transcoding for OTLP formats, buffer pooling, and metrics instrumentation improvements. The approach demonstrates that significant performance gains are possible without language rewrites by focusing on doing only necessary work.

4 Comments

Sort:

func25's user avatar
Phuong Le
@func25
Joined Oct 20. 2023
5.2K

Would you recommend this post?

Copy link
WhatsApp
Facebook
X
New Squad
  • © 2026 Daily Dev Ltd.
  • Guidelines
  • Explore
  • Tags
  • Sources
  • Squads
  • Leaderboard