mirror of
https://github.com/prometheus/prometheus.git
synced 2025-01-30 15:12:27 -08:00
Do not measure size of sync.WaitGroup
Signed-off-by: Marco Pracucci <marco@pracucci.com>
This commit is contained in:
parent
e2c1e7aadc
commit
0a8b79ad29
|
@ -112,7 +112,7 @@ func (c *PostingsForMatchersCache) postingsForMatchersPromise(ctx context.Contex
|
||||||
|
|
||||||
// Estimate the size of the cache entry, in bytes. We use max() because
|
// Estimate the size of the cache entry, in bytes. We use max() because
|
||||||
// size.Of() returns -1 if the value is nil.
|
// size.Of() returns -1 if the value is nil.
|
||||||
estimatedSizeBytes := int64(len(key)) + max(0, int64(size.Of(wg))) + max(0, int64(size.Of(outerErr))) + max(0, int64(size.Of(cloner)))
|
estimatedSizeBytes := int64(len(key)) + max(0, int64(size.Of(outerErr))) + max(0, int64(size.Of(cloner)))
|
||||||
|
|
||||||
c.created(key, c.timeNow(), estimatedSizeBytes)
|
c.created(key, c.timeNow(), estimatedSizeBytes)
|
||||||
return promise
|
return promise
|
||||||
|
|
Loading…
Reference in a new issue