Tag

gomaxprocs

0 views collected around this technical thread.

58 Tech
58 Tech
Apr 13, 2020 · Backend Development

Diagnosing and Optimizing High CPU Usage of a Go Service Migrated to Kubernetes Using Flame Graphs

This article describes how a Go‑based message‑push service migrated to a Kubernetes‑Docker container platform exhibited unexpectedly high CPU usage, the step‑by‑step profiling with go‑tool pprof and flame graphs, analysis of the Go GMP scheduler, and the resolution by configuring GOMAXPROCS to match the container‑allocated cores.

GoKubernetesProfiling
0 likes · 12 min read
Diagnosing and Optimizing High CPU Usage of a Go Service Migrated to Kubernetes Using Flame Graphs
Didi Tech
Didi Tech
Jan 5, 2020 · Backend Development

Investigation and Optimization of High‑Frequency Go Service Timeout in Containers

The study traced severe Redis latency spikes in an 8‑core container to the Go runtime mistakenly reading the host’s CPU count, which created hundreds of threads and scheduler contention; limiting GOMAXPROCS to the container’s quota eliminated the jitter, while further gains were suggested by reducing HMGET calls, tuning GC, and upgrading Go.

CPUGocontainer
0 likes · 14 min read
Investigation and Optimization of High‑Frequency Go Service Timeout in Containers