Instantiate v2::Reciver only after data persistence is complete#560
Closed
arminsabouri wants to merge 2 commits intopayjoin:masterfrom
Closed
Instantiate v2::Reciver only after data persistence is complete#560arminsabouri wants to merge 2 commits intopayjoin:masterfrom
v2::Reciver only after data persistence is complete#560arminsabouri wants to merge 2 commits intopayjoin:masterfrom
Conversation
b4f62e4 to
81f4bc8
Compare
Collaborator
Pull Request Test Coverage Report for Build 13812455333Details
💛 - Coveralls |
DanGould
reviewed
Mar 4, 2025
Contributor
DanGould
left a comment
There was a problem hiding this comment.
Thank you for taking a stab at what I asked for. I don't find it particularly beautiful but also not particularly horrible. Hoping @nothingmuch can chime in with thoughts.
81f4bc8 to
41a1144
Compare
DanGould
reviewed
Mar 4, 2025
Contributor
DanGould
left a comment
There was a problem hiding this comment.
Since this affects the API, and we're nearing a release, I'd like to hold off on merging the individual bit for just the receiver half until we're confident this is the right design. And then I'd like to address sender at the same time so we have one fell swoop of API changes regarding persistence. That's why I converted it to draft.
Sincerely hoping to get @nothingmuch's input on this design and better understand the other options before approving
41a1144 to
dd873fa
Compare
In order to ensure the application has persisted the reciver session before they can use it to handle an proposal we first wrap the reciver in a `EphemeralReciver` struct. Indicating to the application that data will be lost unless it it properly persited via `EphemeralReciver::persist()`. Issue: payjoin#336
2d13ef1 to
9cc8b60
Compare
This was referenced Mar 12, 2025
Collaborator
|
Superseded by #552 |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
In order to ensure the application has persisted the reciver session before they can use it to handle an proposal we first wrap the reciver in a
EphemeralReciverstruct. Indicating to the application that data will be lost unless it it properly persited viaEphemeralReciver::persist().This work is meant to supersedes #552. But I wanted to open a second Pr so we can compare implementation details.
Issue: #336