feat(tiering): Add experimental list node offloading#6944
Conversation
🤖 Augment PR SummarySummary: Adds experimental tiered-storage support for offloading individual Changes:
Technical Notes: List-node offloading is currently constrained (e.g. page-occupancy checks) and uses pointer-based identities ( 🤖 Was this summary useful? React with 👍 or 👎 |
4f08cf6 to
e708544
Compare
46df68e to
3517947
Compare
3517947 to
452b5f7
Compare
452b5f7 to
27d668b
Compare
There was a problem hiding this comment.
Pull request overview
Extends tiered storage beyond key-level PrimeValues to support experimental offloading of individual QList::Node payloads to disk, gated by --tiered_experimental_list_support, by introducing a node-identity (ListNodeId) and wiring list-tiering callbacks into QList.
Changes:
- Introduces
ListNodeIdplusPendingId/ReadIdvariants so tiering I/O can address both keys and list nodes uniformly. - Adds list-node offload/onload/delete callback hooks (
QList::TieringParams) and connects them fromlist_familywhen tiered storage is available. - Adds a new test suite (
ListNodeTieringTest) to validate list node stash/load/delete behaviors.
Reviewed changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 10 comments.
Show a summary per file
| File | Description |
|---|---|
| src/server/tiering/common.h | Adds ListNodeId, expands PendingId, introduces ReadId. |
| src/server/tiering/op_manager.h | Extends OwnedEntryId to include ListNodeId. |
| src/server/tiering/op_manager.cc | Supports owning/logging of ListNodeId. |
| src/server/tiered_storage.h | Generalizes Read/CancelStash, adds list-node helpers, adds IsClosed(). |
| src/server/tiered_storage.cc | Implements list-node stash/read paths and feature gating flag wiring. |
| src/server/list_family.cc | Wires tiering callbacks into QList via ListWrapper/promotion. |
| src/core/qlist.h | Adds node io_pending, external record, and tiering callbacks. |
| src/core/qlist.cc | Implements offload/onload/delete lifecycle hooks and Node::SetExternal. |
| src/core/tiering_types.h / .cc | Extends FragmentRef to support QList::Node* fragments. |
| src/core/compact_object.h / .cc | Adds ExternalRep::LIST_NODE and object-type mapping behavior. |
| src/server/tiered_storage_test.cc | Adds list node tiering test coverage. |
| src/server/hset_family.cc | Adapts tiered Read call to new signature. |
| src/server/db_slice.cc | Adapts CancelStash calls to new PendingId signature. |
77572ce to
7e7edfe
Compare
|
augment review |
61cdbc9 to
90afdd0
Compare
|
wow this is a lot of code 😟 |
dranikpg
left a comment
There was a problem hiding this comment.
It's really hard to review such a large PR as if its "ready to be commited" code. I know it's very cumbersome to split all of this. I usually make different commits and there are lots of refactoring parts here (uniting db_index, key), extending ListWrapper, etc.
I will take a look a little later at the other parts. I'm not much in context of list tiering yet
|
Please rebase and resolve conflicts. |
|
augment review |
ad4aa44 to
622c609
Compare
|
augment review |
36f213f to
27f7adc
Compare
5e50251 to
fb8f92a
Compare
09b209a to
d4572a5
Compare
Extend tiered storage to offload individual QList nodes to disk, gated by --tiered_experimental_list_support. Key changes: - Add ListNodeId (dbid, node*, ql*) as a new tiering identity type alongside KeyRef; introduce PendingId/ReadId variants so OpManager can handle both key-level and node-level I/O uniformly. - Add tiering callbacks (offload_cb, onload_cb, delete_cb) to QList::TieringParams. PromoteToQLIfNeeded now wires them up when tiered storage is available, using the new db_id_ member on ListWrapper to store DbIndex for usage. - Update CancelStash / ReadInternal signatures to accept the generic PendingId / ReadId types instead of (dbid, key). - Add IsClosed() / is_closed_ guard so delete_cb skips I/O after TieredStorage::Close() is called. - Expose StashListNode / ReadTieredListNode free functions used by the ListWrapper callbacks. - Added ListNodeTieringTest suite Signed-off-by: mkaruza <mario@dragonflydb.io>
Don't stash list nodes if don't occupty whole page (either raw or compressed).
d4572a5 to
7316313
Compare
I join the sentiment. There is no reason to review it as a whole. I should be split into 3 at least. Lets start with |
Extend tiered storage to offload individual QList nodes. Offloading is supported
for RAW node objects. Functionality is controlled with flag
--tiered_experimental_list_support.
Key changes:
alongside KeyRef; introduce PendingId/ReadId variants so OpManager
can handle both key-level and node-level I/O uniformly.
QList::TieringParams. PromoteToQLIfNeeded now wires them up when
tiered storage is available, using the new db_id_ member on
ListWrapper to store DbIndex for usage.
PendingId / ReadId types instead of (dbid, key).
ListWrapper callbacks.
from tiered storage.