Skip to content

Conversation

hawkingrei
Copy link
Member

@hawkingrei hawkingrei commented Sep 18, 2023

In containerized deployments, Go runtime, by default, uses the total number of CPU cores available on the machine as the value of GOMAXPROCS, without considering the CPU quota of the container. This can lead to suboptimal performance and potential throttling issues as more goroutines may get scheduled than the available CPU quota.

Uber's automaxprocs library automatically adjusts the GOMAXPROCS value to match the Linux container's CPU quota, leading to more efficient CPU usage and potentially better performance.

Signed-off-by: Weizhen Wang <[email protected]>
Signed-off-by: Weizhen Wang <[email protected]>
@hawkingrei hawkingrei merged commit 10e1032 into pingcap:master Sep 18, 2023
@hawkingrei hawkingrei deleted the set_right_gomaxprocs branch September 18, 2023 09:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants