lnd.xprv/invoices
carla 34de5922ed
multi: add height-based invoice expiry
This commit adds height-based invoice expiry for hodl invoices
that have active htlcs. This allows us to cancel our intentionally
held htlcs before channels are force closed. We only add this for
hodl invoices because we expect regular invoices to automatically
be resolved.

We still keep hodl invoices in the time-based expiry queue,
because we want to expire open invoices that reach their timeout
before any htlcs are added. Since htlcs are added after the
invoice is created, we add new htlcs as they arrive in the
invoice registry. In this commit, we allow adding of duplicate
entries for an invoice to be added to the expiry queue as each
htlc arrives to keep implementation simple. Our cancellation
logic can already handle the case where an entry is already
canceled, so this is ok.
2021-05-11 08:45:29 +02:00
..
interface.go invoices: expose AMPRecord() method on Payload 2021-03-03 16:26:39 -08:00
invoice_expiry_watcher_test.go multi: add height-based invoice expiry 2021-05-11 08:45:29 +02:00
invoice_expiry_watcher.go multi: add height-based invoice expiry 2021-05-11 08:45:29 +02:00
invoiceregistry_test.go multi: add height-based invoice expiry 2021-05-11 08:45:29 +02:00
invoiceregistry.go multi: add height-based invoice expiry 2021-05-11 08:45:29 +02:00
log.go invoices: remove dead code from logger 2020-04-24 19:15:08 +02:00
resolution_result.go invoices: add TestSpontaneousAmpPayment 2021-04-07 12:08:35 -07:00
resolution.go invoices: split resolution result into settle, fail and accept enums 2020-02-06 19:41:39 +02:00
test_utils_test.go multi: add height-based invoice expiry 2021-05-11 08:45:29 +02:00
update.go invoices: reconstruct AMP child preimages 2021-04-07 12:08:35 -07:00