Skip to content

Update KVStore and KVStoreSync arguments to being owned - #3974

Merged
joostjager merged 1 commit into
lightningdevkit:mainfrom
joostjager:owned-kvstore-args
Aug 1, 2025
Merged

Update KVStore and KVStoreSync arguments to being owned#3974
joostjager merged 1 commit into
lightningdevkit:mainfrom
joostjager:owned-kvstore-args

Conversation

@joostjager

@joostjagerjoostjager commented Jul 30, 2025

Copy link
Copy Markdown
Contributor

This avoids the need for async KVStore implementations to copy data.

Preparation for #3931

@ldk-reviews-bot

ldk-reviews-bot commented Jul 30, 2025

Copy link
Copy Markdown

👋 Thanks for assigning @tnull as a reviewer!
I'll wait for their review and will help manage the review process.
Once they submit their review, I'll check if a second reviewer would be helpful.

@joostjager
joostjagerforce-pushed the owned-kvstore-args branch 2 times, most recently from 2329565 to 619ec16CompareJuly 30, 2025 14:24
@codecov

codecovBot commented Jul 30, 2025

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 89.47368% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 88.90%. Comparing base (664511b) to head (23a1eb7).
⚠️ Report is 17 commits behind head on main.

Files with missing linesPatch %Lines
lightning/src/util/persist.rs66.66%2 Missing and 1 partial ⚠️
lightning/src/util/test_utils.rs50.00%0 Missing and 1 partial ⚠️
Additional details and impacted files
@@ Coverage Diff @@## main #3974 +/- ##
==========================================
- Coverage 88.91% 88.90% -0.01% 
==========================================
Files 174 174 Lines 124232 124233 +1 Branches 124232 124233 +1 ==========================================
- Hits 110455 110450 -5 - Misses 11301 11304 +3 - Partials 2476 2479 +3 
FlagCoverage Δ
fuzzing22.61% <0.00%> (ø)
tests88.73% <89.47%> (-0.01%)⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@joostjager
joostjager marked this pull request as ready for review July 30, 2025 15:04
@joostjager
joostjager requested review from TheBlueMatt and tnull and removed request for TheBlueMattJuly 30, 2025 15:04
Comment threadlightning/src/util/persist.rs Outdated
Comment threadlightning/src/util/persist.rs Outdated
@ldk-reviews-bot

Copy link
Copy Markdown

👋 The first review has been submitted!

Do you think this PR is ready for a second reviewer? If so, click here to assign a second reviewer.

@joostjager
joostjagerforce-pushed the owned-kvstore-args branch 2 times, most recently from daf19e3 to d37c595CompareJuly 31, 2025 07:12
@joostjager

Copy link
Copy Markdown
ContributorAuthor

@joostjager
joostjager requested a review from tnullJuly 31, 2025 07:51
@tnulltnull mentioned this pull request Jul 31, 2025

@tnulltnull left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Switch to Display looks good, but this is pending on the other discussion.

@joostjager

Copy link
Copy Markdown
ContributorAuthor

Updated PR according to offline discussion outcome. Only make the data to write owned for both sync and async.

This avoids the need for async KVStore implementations to copy data.
@joostjager
joostjager requested a review from tnullJuly 31, 2025 14:31

@tnulltnull left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@joostjager

Copy link
Copy Markdown
ContributorAuthor

Going to land this to unblock the follow up. Approach has been discussed wider offline, and PR can be checked post-merge @TheBlueMatt.

@joostjager
joostjager merged commit 61e5819 into lightningdevkit:mainAug 1, 2025
24 of 25 checks passed
Sign up for freeto 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.

3 participants

@joostjager@ldk-reviews-bot@tnull