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

[PoC] Cgroup runtime extension #35472

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

rogercoll
Copy link
Contributor

Description:

Link to tracking Issue: #30289

Testing:

Documentation:

@rogercoll
Copy link
Contributor Author

Manually tested with a modified version of the OpenTelemetry collector that exposes the internal runtime metrics: https://pkg.go.dev/runtime/metrics

Deployed with very limited cgroup resources:

        resources:
          requests:
            cpu: "50m"      # Minimal CPU request
            memory: "64Mi"  # Minimal memory request
          limits:
            cpu: "100m"     # Minimal CPU limit
            memory: "128Mi" # Minimal memory limit

Resulting runtime metrics:

# HELP go_gc_gomemlimit_bytes Go runtime memory limit configured by the user, otherwise math.MaxInt64. This value is set by the GOMEMLIMIT environment variable, and the runtime/debug.SetMemoryLimit function. Sourced from /gc/gomemlimit:bytes
# TYPE go_gc_gomemlimit_bytes gauge
go_gc_gomemlimit_bytes 1.20795955e+08

...
# HELP go_sched_gomaxprocs_threads The current runtime.GOMAXPROCS setting, or the number of operating system threads that can execute user-level Go code simultaneously. Sourced from /sched/gomaxprocs:threads
# TYPE go_sched_gomaxprocs_threads gauge
go_sched_gomaxprocs_threads 1

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.

1 participant