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

chore: snapshot/tiering improvements #4661

Merged
merged 1 commit into from
Mar 5, 2025
Merged

chore: snapshot/tiering improvements #4661

merged 1 commit into from
Mar 5, 2025

Conversation

romange
Copy link
Collaborator

@romange romange commented Feb 25, 2025

Mainly comments and refactorings.

There are two functional differrences:

  1. flush serialized entries in case we gathered at least K delayed
    entries coming from tiered entities.
  2. allow loading snapshots larger than memory for tiered enabled datastores.

Also pull latest helio with some bug fixes in gcs code.

Signed-off-by: Roman Gershman roman@dragonflydb.io

@@ -89,6 +89,20 @@ class SliceSnapshot {
snapshot_fb_.JoinIfNeeded();
}

uint64_t snapshot_version() const {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

just moved here, no changes

{db_indx, PrimeKey(pk.ToString()), std::move(future), expire_time, mc_flags});
++type_freq_map_[RDB_TYPE_STRING];
// TODO: we loose the stickiness attribute bly cloning like this PrimeKey.
SerializeExternal(db_indx, PrimeKey{pk.ToString()}, pv, expire_time, mc_flags);
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

code moved into SerializeExternal

PrimeValue pv{entry.value.Get()}; // Might block until the future resolves.

// TODO: to introduce RdbSerializer::SaveString that can accept a string value directly.
serializer_->SaveEntry(entry.key, pv, entry.expire, entry.mc_flags, entry.dbid);
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

we had a bug with reversed mc_flags and dbid that is fixed here.

@romange romange force-pushed the TieredImprov branch 4 times, most recently from d20f06f to 15558f3 Compare March 4, 2025 12:54

Verified

This commit was signed with the committer’s verified signature.
dsanders11 David Sanders
Mainly comments and refactorings.

There are two functional differrences:
1. flush serialized entries in case we gathered at least K delayed
entries coming from tiered entities.
2. allow loading snapshots larger than memory for tiered enabled datastores.

Co-authored-by: Kostas Kyrimis  <kostas@dragonflydb.io>
Signed-off-by: Roman Gershman <roman@dragonflydb.io>
@romange romange requested a review from kostasrim March 5, 2025 07:29
Copy link
Contributor

@kostasrim kostasrim left a comment

Choose a reason for hiding this comment

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

lgtm

@romange romange merged commit b53de2e into main Mar 5, 2025
10 checks passed
@romange romange deleted the TieredImprov branch March 5, 2025 07:43
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.

None yet

2 participants