runtime/metrics: add /gc/gomemlimit:bytes

For #56857

Change-Id: I184d752cc615874ada3d0dbc6ed1bf72c8debd0f
Reviewed-on: https://go-review.googlesource.com/c/go/+/497316
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Felix Geisendörfer <felix.geisendoerfer@datadoghq.com>
Auto-Submit: Michael Knyszek <mknyszek@google.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
Reviewed-by: David Chase <drchase@google.com>
This commit is contained in:
Felix Geisendörfer 2023-05-23 11:16:28 +02:00 committed by Gopher Robot
parent cb6b45a993
commit 2544b1051e
4 changed files with 26 additions and 0 deletions

View file

@ -147,6 +147,11 @@ Below is the full list of supported metrics, ordered lexicographically.
/gc/cycles/total:gc-cycles
Count of all completed GC cycles.
/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.
/gc/heap/allocs-by-size:bytes
Distribution of heap allocations by approximate size.
Bucket counts increase monotonically. Note that this does not