Performance bottlenecks of Go application on Kubernetes with non-integer (floating) CPU allocation
May 23, 2023Shubham Badkur

Summary
This post details the investigation and resolution of CPU throttling and consumer lag issues in Go applications on Kubernetes. The core problem was identified as the interaction between Kubernetes CPU allocation, the `AUTO-GOMAXPROCS` setting in Go (which rounds down non-integer values), and the Vertical Pod Autoscaler (VPA). The solution involved ensuring VPA proposes integer CPU values and setting a minimum integer CPU limit for resource-intensive pipelines to prevent performance degradation.