rust-lightning/lightning
Matt Corallo 0fcc34b9b5 Regenerate PendingHTLCsForwardable on reload instead of serializing
When we are prepared to forward HTLCs, we generate a
PendingHTLCsForwardable event with a time in the future when the
user should tell us to forward. This provides some basic batching
of forward events, improving privacy slightly.

After we generate the event, we expect users to spawn a timer in
the background and let us know when it finishes. However, if the
user shuts down before the timer fires, the user will restart and
have no idea that HTLCs are waiting to be forwarded/received.

To fix this, instead of serializing PendingHTLCsForwardable events
to disk while they're pending (before the user starts the timer),
we simply regenerate them when a ChannelManager is deserialized
with HTLCs pending.

Fixes #1042
2021-09-29 19:20:38 +00:00
..
src Regenerate PendingHTLCsForwardable on reload instead of serializing 2021-09-29 19:20:38 +00:00
Cargo.toml Update versions to 0.0.100 and lightning-invoice to 0.8 2021-08-17 18:55:07 +00:00