Skip to content

Commit a6039b9

Browse files
committed
Replace maze of BOLT11 payment utilities with parameter generators
`lightning-invoice` was historically responsible for actually paying invoices, handling retries and everything. However, that turned out to be buggy and hard to maintain, so the payment logic was eventually moved into `ChannelManager`. However, the old utilites remain. Because our payment logic has a number of tunable parameters and there are different ways to pay a BOLT11 invoice, we ended up with six different methods to pay or probe a BOLT11 invoice, with more requested as various options still were not exposed. Instead, here, we replace all six methods with two simple ones which return the arguments which need to be passed to `ChannelManager`. Those arguments can be further tweaked before passing them on, allowing more flexibility.
1 parent 6e40e5f commit a6039b9

File tree

1 file changed

+89
-302
lines changed

1 file changed

+89
-302
lines changed

0 commit comments

Comments
 (0)