Skip to content

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

Merged
Ted Hart (TedHartMS) merged 2 commits into
mainfrom
tedhar/nulldev-chkpt-fix
Mar 25, 2024
Merged

Ensure that all in-memory records are checkpointed when not using --storage-tier#117
Ted Hart (TedHartMS) merged 2 commits into
mainfrom
tedhar/nulldev-chkpt-fix

Conversation

@TedHartMS

@TedHartMS Ted Hart (TedHartMS) commented Mar 24, 2024

Copy link
Copy Markdown
Contributor

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
Ted Hart (TedHartMS) merged commit 2513b20 into main Mar 25, 2024
@TedHartMS
Ted Hart (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.

2 participants