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

Ensure that all in-memory records are checkpointed when not using --storage-tier #117

Merged
merged 2 commits into from
Mar 25, 2024

Conversation

TedHartMS
Copy link
Contributor

@TedHartMS TedHartMS commented Mar 24, 2024

Currently, a snapshot checkpoint in Tsavorite only takes a copy of records in mutable region (90% of memory) by default, since earlier records are expected to be flushed to disk and therefore available after recovery.

But when Garnet is configured to run as a cache, i.e., entirely in main memory, there is no backing device (rather, the backing device is a NullDevice).

This PR proposes for a snapshot checkpoint to include the immutable region of memory in this case. This will ensure that DBSIZE of Garnet in "cache mode" (i.e., not using --storage-tier) before a SAVE and after a restart with --recover will be the same. That is, we will not lose the cache entries in the immutable region of memory.

@TedHartMS TedHartMS requested a review from badrishc March 24, 2024 19:24
@TedHartMS TedHartMS merged commit 2513b20 into main Mar 25, 2024
12 checks passed
@TedHartMS TedHartMS deleted the tedhar/nulldev-chkpt-fix branch March 25, 2024 06:17
@github-actions github-actions bot locked and limited conversation to collaborators May 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants