-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
WAL backpressure #3218
Merged
Merged
WAL backpressure #3218
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Codecov Report
@@ Coverage Diff @@
## master #3218 +/- ##
==========================================
+ Coverage 63.22% 63.30% +0.08%
==========================================
Files 196 197 +1
Lines 16671 16728 +57
==========================================
+ Hits 10540 10590 +50
- Misses 5174 5187 +13
+ Partials 957 951 -6
|
cyriltovena
reviewed
Jan 26, 2021
cyriltovena
reviewed
Jan 27, 2021
cyriltovena
approved these changes
Jan 27, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
I'm a bit scared of sync.Cond I need to read more about those.
owen-d
force-pushed
the
wal/backpressure
branch
from
January 27, 2021 20:57
9ef6ff4
to
78a44bf
Compare
cyriltovena
pushed a commit
to cyriltovena/loki
that referenced
this pull request
Jun 11, 2021
…rafana#3218) * Speed up the listing of rule groups on the Ruler Configuration API Signed-off-by: gotjosh <[email protected]> * Update changelog based on feedback. Signed-off-by: Peter Štibraný <[email protected]> Co-authored-by: Peter Štibraný <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What
This PR introduces a backpressure mechanic to the ingester during WAL replay. This is primarily to allow specifying an upper bound of memory devoted to the replay which will be drained to storage once hit.
This also includes
UncompressedBytes
. @slim-bean graciously cut2.0.1
as a rollback target that supports this schema in the case of unforeseen failures.ingester.wal-replay-memory-ceiling
loki_ingester_wal_recovered_bytes_total
andloki_ingester_wal_bytes_in_use
Details
Note, this will cause a drop in the chunk dedupe ratio when it is hit, thus I suggest specifying the limit as high as is tolerable to minimize the chances. Generally, the backpressure drainage should only happen after outages when the WAL is large or after moving scaling down memory budgets.