Skip to content

Conversation

bboreham
Copy link
Contributor

@bboreham bboreham commented Jul 2, 2019

This is a terrible, terrible thing. I apologise.

It allows the heap size to be made bigger, to make Go's GC run less often and use less CPU. See golang/go#23044
Particularly aimed at distributors.

This allows the heap size to be made bigger, to make Go's GC run less
often and use less CPU.  See golang/go#23044

Signed-off-by: Bryan Boreham <[email protected]>
Copy link
Contributor

@csmarchbanks csmarchbanks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep. It's awful and will likely really help with tail latency as well (if I remember the uber article correctly at least).

level.Error(util.Logger).Log("msg", "error running Cortex", "err", err)
}

runtime.KeepAlive(ballast)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aha! I tried doing this in a different project awhile ago and did not know about KeepAlive.

@bboreham bboreham merged commit 561033f into master Jul 3, 2019
@bboreham bboreham deleted the ballast branch July 3, 2019 14:41
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.

2 participants