Skip to content

feat(server): Journal omits#7060

Draft
dranikpg wants to merge 8 commits intodragonflydb:mainfrom
dranikpg:new-journal-omits
Draft

feat(server): Journal omits#7060
dranikpg wants to merge 8 commits intodragonflydb:mainfrom
dranikpg:new-journal-omits

Conversation

@dranikpg
Copy link
Copy Markdown
Contributor

@dranikpg dranikpg commented Apr 3, 2026

Experimental journal omits

image

@dranikpg dranikpg force-pushed the new-journal-omits branch 2 times, most recently from 751383e to cda32b8 Compare April 8, 2026 16:15
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
@dranikpg dranikpg force-pushed the new-journal-omits branch from cda32b8 to ffbdbf5 Compare April 16, 2026 07:50
Comment thread src/server/db_slice.h Outdated
bool expired_keys_events_recording_ = true;

// Provided for the next FindMutableInternal operation
MutationHints* mutation_hints_ = nullptr;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

what is the size of MutationHints ? why do you need to pass by pointer and not by value?
looks fragile

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Because it is also used to get output variables

Comment thread src/server/journal/journal.cc Outdated

bool HasRegisteredCallbacks() {
return journal_slice.HasRegisteredCallbacks();
unsigned CallbackNumber() {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

CallbackNumber is not a great name.

Comment thread src/server/string_family.cc Outdated
}
}

DbSlice::MutationHints hints{.hint{.single_key = true, .support_omit = explicit_journal_}};
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

can we do it more elegantly?

  1. at least in this example you pass hints with .single_key = true and set support_omit then why passing them at all? why not pass a final boolean true if the caller supports omit
  2. the boolean could be added to op_args_.db_cntx, maybe so you won't need to inject this before the find call.
  3. skip_journal_ can be returned by AddOrFind inside op_res.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I agree, let's move it to existing structures

Signed-off-by: Vladislav <vlad@dragonflydb.io>
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
@dranikpg dranikpg force-pushed the new-journal-omits branch from 7fdf5f8 to 99c0270 Compare April 18, 2026 20:18
Signed-off-by: Vladislav <vlad@dragonflydb.io>
@dranikpg
Copy link
Copy Markdown
Contributor Author

dranikpg commented May 3, 2026

Will rebase to include #7253

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