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
Persist rescan progress. #4425
Persist rescan progress. #4425
Conversation
c920e38
to
cbd8fa8
Compare
cbd8fa8
to
c8a3b8d
Compare
Still relevant? |
ping @roeierez |
IIRC @cfromknecht we were hesitant to include this due to some spooky interaction at a distance w.r.t the spend hints themselves? The functionality is already in neutrino, and this PR would just make that useable for lnd users. |
@cfromknecht ping |
@roeierez do you have the bandwidth to revive this PR? I take it Breez is already running this in production, correct? |
Adding persistency to neutrino re-scan progress. In case the re-scan failed in the middle or the node was restarted before the re-scan has been completed this fix will start from the last point instead of the beginning. On long re-scan , such as old channels on mobile devices this is crucial.
c8a3b8d
to
935e714
Compare
Rebased. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🥟
ping @halseth |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
This PR follows up to neutrino PR: lightninglabs/neutrino#198 and handles the use case where
old channels unable to finish their re-scan on mobile devices waisting lots of bandwidth on every restart.
While there is a mechanism of "SpendHint" cache to persist the rescan progress, it is only get updated at the end of the process.
This PR adds additional updates along the way in a similar way to how btcwallet does for the initial rescan.