-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Peer backup #8490
Open
Chinwendu20
wants to merge
20
commits into
lightningnetwork:master
Choose a base branch
from
Chinwendu20:peer-backup
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+1,530
−445
Open
Peer backup #8490
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
52d310c
peer: Change `createTestPeer` name.
6d06ced
peer: `createTestPeerWithChannel` returns a struct
be3f077
peer: Create mockswitch, publTx, notifier in ..
637d6ab
peer: Add new function to create test peer.
4f70129
peer: Add `startPeer` test function
3322038
lnwire: Add feature bits for peer backup storage.
Chinwendu20 71027b8
lnwire: Add peer backup storage message.
Chinwendu20 5a8be6b
multi: Add optional peer storage feature config
Chinwendu20 abbb190
peer: Add storage layer to handle `PeerStorage`
Chinwendu20 8b0bd5b
lnd: Include a Kvdb impl for peer.PeerDataStore
Chinwendu20 ccecf4b
lncfg+lnd: Add PeerStorage kvdb to DB backend
Chinwendu20 63c5f2d
lnd: Include kvdbStorage in server and peer config
Chinwendu20 562d40a
peer: Create hasActiveChannels function.
Chinwendu20 46d3a2a
peer: Add `IsDisconnected` method to brontide.
Chinwendu20 b9d38e5
peer: Make brontide know peer backup storage msgs
Chinwendu20 0b66b3d
peer: Add handler for peerStorageRetrieval
Chinwendu20 9dedf1a
peer: Add handler for `PeerStorage` message
Chinwendu20 12d4c95
peer: Add PeerStorageWriter to brontide.
Chinwendu20 93af069
peer: Send peers their data on connection.
Chinwendu20 59f829b
docs: Added release note
Chinwendu20 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
As discussed in the main PR thread this is not the approach we want to take. You shouldn't need a separate peerStorageWriter thread. It is fine to persist it in the main handler thread, or fork a single goroutine for overwriting the data so it doesn't block the main readHandler thread.
This will also alleviate the need to use
Cond
s which are notoriously difficult to use correctly.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.
Do you mean in the
Store
method?