gudnuf / bolt12-prism

CLN plugin for lightning prisms using BOLT 12
15 stars 5 forks source link

Feature Request - Scheduled Outlay Clearing #94

Open farscapian opened 3 months ago

farscapian commented 3 months ago

Prism bindings track a member outlay variable that represents the sats intended for the destination. At the moment, payout attempts only occur when an incoming payment arrives on an offer. It would be preferable for the prism plugin to pay-out any member outlays (where outlay>payment_threshold_msat) periodically in the background (on a configurable basis).

A related problem is that when a member outlay has a large positive number, the payout tries to make the entire payment in one attempt, which usually results in payment failure (why is the outlay large and positive in the first place?). A better approach might be to pay-out smaller values in attempt to clear outlays.