Skip to content

Conversation

@dranikpg
Copy link
Contributor

Two phase stashing divides the process into two parts:

  1. Allocating space on the file with external alloc and preparing a buffer
  2. Writing the buffer

This allows to first determine if there is enough space and get a destination buffer. Only then we proceed with serializing the value (which will be much more costly for hashmaps!) directly into the destination buffer.

@dranikpg dranikpg marked this pull request as ready for review October 31, 2025 09:06
@dranikpg dranikpg requested a review from romange November 3, 2025 13:57
@dranikpg dranikpg requested a review from romange November 5, 2025 14:08
Co-authored-by: Roman Gershman <[email protected]>
Signed-off-by: Vladislav <[email protected]>
@dranikpg dranikpg enabled auto-merge (squash) November 5, 2025 14:58
@dranikpg dranikpg merged commit 15226e1 into dragonflydb:main Nov 5, 2025
10 checks passed
@dranikpg dranikpg deleted the disk-store-2step branch November 5, 2025 16:46
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