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

Make FUNCTION RESTORE FLUSH flush async based on lazyfree-lazy-user-flush #1254

Merged
merged 6 commits into from
Nov 21, 2024

Conversation

enjoy-binbin
Copy link
Member

@enjoy-binbin enjoy-binbin commented Nov 4, 2024

FUNCTION RESTORE have a FLUSH option, it will delete all the existing
libraries before restoring the payload. If for some reasons, there are
a lot of libraries, we will block a while in here.

Adding a new functionsLibCtxFreeGeneric, it accepts a async parameter
to determine how to free the function ctx.

…lush

FUNCTION RESTORE have a FLUSH option, it will delete all the existing
libraries before restoring the payload. If for some reasons, there are
a lot of libraries, we will block a while in here.

Signed-off-by: Binbin <[email protected]>
Copy link

codecov bot commented Nov 4, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 70.69%. Comparing base (4986310) to head (376bd5a).
Report is 2 commits behind head on unstable.

Additional details and impacted files
@@             Coverage Diff              @@
##           unstable    #1254      +/-   ##
============================================
+ Coverage     70.68%   70.69%   +0.01%     
============================================
  Files           115      115              
  Lines         63177    63175       -2     
============================================
+ Hits          44657    44664       +7     
+ Misses        18520    18511       -9     
Files with missing lines Coverage Δ
src/functions.c 95.71% <100.00%> (+0.02%) ⬆️
src/replication.c 87.27% <100.00%> (+<0.01%) ⬆️

... and 11 files with indirect coverage changes

---- 🚨 Try these New Features:

src/replication.c Outdated Show resolved Hide resolved
@enjoy-binbin
Copy link
Member Author

This doesn't look like a major change, i am going to merge it. @zuiderkwast do you want to take a quick look before i merge it?

Copy link
Contributor

@zuiderkwast zuiderkwast left a comment

Choose a reason for hiding this comment

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

Good idea! Just a comment about the structure of functions.

src/functions.c Outdated Show resolved Hide resolved
src/lazyfree.c Outdated Show resolved Hide resolved
Signed-off-by: Binbin <[email protected]>
src/functions.c Outdated Show resolved Hide resolved
Copy link
Contributor

@zuiderkwast zuiderkwast left a comment

Choose a reason for hiding this comment

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

Yes, this is better structure. I hope you agree. 😄

@enjoy-binbin enjoy-binbin merged commit 6038eda into valkey-io:unstable Nov 21, 2024
48 checks passed
@enjoy-binbin enjoy-binbin deleted the function_restore_async branch November 21, 2024 13:02
@enjoy-binbin enjoy-binbin added the release-notes This issue should get a line item in the release notes label Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-notes This issue should get a line item in the release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants