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

Implement JIT spec open channel flow #73

Closed
JssDWt opened this issue Mar 20, 2023 · 1 comment
Closed

Implement JIT spec open channel flow #73

JssDWt opened this issue Mar 20, 2023 · 1 comment
Assignees

Comments

@JssDWt
Copy link
Collaborator

JssDWt commented Mar 20, 2023

Identify forwards from the proposed JIT channel spec based on their SCID. If the SCID is persisted as a JIT channel request, fall into a channel flow that should be newly created as implementation of this issue.

  • aggregate htlcs until all parts sum up to at least payment_size plus opening_fee
    • point of caution, think about restarts of lspd and/or the lightning node. Should be able to handle both replays of the same htlc when the node is restarted and missing replays of htlcs when lspd is restarted.
  • Make sure htlc timeouts are handled appropriately, either by the node itself of by lspd explicitly. In either case, lspd will have to know about htlc expiry.
  • keep track of when htlcs 'expire' through expiry of valid_until of the opening parameters.
  • Make a decision on what to do with too many payment parts. Probably want to just take the excess amount?
  • When there are enough payment parts, make sure the client is connected and valid_until has not expired.
  • open the channel, when channel_ready is received, forward the htlcs with lowered amounts defined in the provided algorithm.
  • Probably we won't do anything custom with the channel alias. We'll let the node specify a new channel alias for the channel open.
  • Caution with htlcs that arrive after the decision to open the channel, those need to be handled as well.
@JssDWt JssDWt self-assigned this Mar 20, 2023
@JssDWt
Copy link
Collaborator Author

JssDWt commented Aug 7, 2023

Closing in favor of #109

@JssDWt JssDWt closed this as completed Aug 7, 2023
@JssDWt JssDWt reopened this Aug 7, 2023
@JssDWt JssDWt closed this as not planned Won't fix, can't repro, duplicate, stale Aug 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant