Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto configure GOMAXPROCS #2022

Open
enocom opened this issue Nov 9, 2023 · 1 comment
Open

Auto configure GOMAXPROCS #2022

enocom opened this issue Nov 9, 2023 · 1 comment
Assignees
Labels
priority: p3 Desirable enhancement or fix. May not be included in next release. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.

Comments

@enocom
Copy link
Member

enocom commented Nov 9, 2023

Feature Description

We should either document this or do it automatically.

See https://www.riverphillips.dev/blog/go-cfs/ for details.

For a library solution, see https://github.com/uber-go/automaxprocs.

Go might just handle this for us: golang/go#33803.

Sample code

No response

Alternatives Considered

No response

Additional Details

No response

@enocom enocom added priority: p3 Desirable enhancement or fix. May not be included in next release. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. labels Nov 9, 2023
@enocom enocom self-assigned this Nov 9, 2023
@enocom
Copy link
Member Author

enocom commented Feb 22, 2024

Or just add this to our docs:

       env:
       - name: GOMAXPROCS
          valueFrom:
            resourceFieldRef:
              resource: limits.cpu

https://www.ardanlabs.com/blog/2024/02/kubernetes-cpu-limits-go.html

@enocom enocom assigned jackwotherspoon and unassigned enocom May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p3 Desirable enhancement or fix. May not be included in next release. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

No branches or pull requests

2 participants