elastic / elastic/fleet-server

Automatically set GOMAXPROCS

Open
#1,633 1 comment 0 reactions 0 assignees View on GitHub
Project:FleetScaling Team:Elastic-Agent-Control-Plane
Dominant language
Go
Stars
113
Forks
117
Avg merge
1d 16h
Merged PRs (30d)
112

Description

**Describe the enhancement:**
Automatically set GOMAXPROCS when Fleet Server is run in a container with a CFS quota set to minimize CPU throttling.

See https://github.com/elastic/apm-server/issues/7967 and https://github.com/elastic/apm-server/pull/8278 for more context. https://github.com/uber-go/automaxprocs can be used to easily add this feature.

**Describe a specific use case for the enhancement or feature:**
Setting GOMAXPROCS based on the configured CPU quota makes performance more predicatible in containerized environments. Kubernetes deployments are particularly likely to experience problems from unoptimized GOMAXPROCS configurations.

Related:
- https://github.com/elastic/beats/issues/31920
- https://github.com/elastic/elastic-agent-shipper/issues/55

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.