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

(release/v1.6) Confirm badgerMove entry required before rewrite (#1302) #1502

Merged
merged 4 commits into from
Sep 9, 2020

Conversation

NamanJain8
Copy link
Contributor

@NamanJain8 NamanJain8 commented Sep 8, 2020

Value log badgerMove entries for deleted keys are always rewritten.
This leads to exponential DB size growth in heavy write/delete use
cases with value pointer entries. To prevent this, a check has been
added to confirm the value is still needed for badgerMove entries.

(cherry picked from commit 3e1cdd9)

This required fixing the build


This change is Reviewable

Value log badgerMove entries for deleted keys are always rewritten.
This leads to exponential DB size growth in heavy write/delete use
cases with value pointer entries. To prevent this, a check has been
added to confirm the value is still needed for badgerMove entries.

(cherry picked from commit 3e1cdd9)
@jarifibrahim
Copy link
Contributor

Build failed because of

  ./db_test.go:411:6: opts.KeepL0InMemory undefined (type Options has no field or method KeepL0InMemory)

Copy link
Contributor

@jarifibrahim jarifibrahim left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: 0 of 2 files reviewed, all discussions resolved (waiting on @ashish-goswami, @jarifibrahim, and @manishrjain)

@NamanJain8 NamanJain8 merged commit 654779f into release/v1.6 Sep 9, 2020
@NamanJain8 NamanJain8 deleted the naman/cp-3 branch September 9, 2020 14:38
mYmNeo pushed a commit to mYmNeo/badger that referenced this pull request Jan 16, 2023
…permodeinc#1302) (hypermodeinc#1502)

* Confirm `badgerMove` entry required before rewrite (hypermodeinc#1302)

Value log badgerMove entries for deleted keys are always rewritten.
This leads to exponential DB size growth in heavy write/delete use
cases with value pointer entries. To prevent this, a check has been
added to confirm the value is still needed for badgerMove entries.

(cherry picked from commit 3e1cdd9)

* remove KeepL0InMemory in db_test

Co-authored-by: Julian Hegler <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants