]> git.bitcoin.ninja Git - rust-lightning/commit
Send update_channel messages to re-enable a disabled channel
authorMatt Corallo <git@bluematt.me>
Fri, 7 May 2021 20:56:10 +0000 (20:56 +0000)
committerMatt Corallo <git@bluematt.me>
Thu, 13 May 2021 20:53:53 +0000 (20:53 +0000)
commitac3380e4704ed90503e39c1d9d647aed54cce5de
treeffa8bd7570f557e23d6dffd10f7e72fcb67f3be3
parent0ac3b444bea11eaab10632cff1a51c2b666ba75b
Send update_channel messages to re-enable a disabled channel

Currently, we only send an update_channel message after
disconnecting a peer and waiting some time. We do not send a
followup when the peer has been reconnected for some time.

This changes that behavior to make the disconnect and reconnect
channel updates symmetric, and also simplifies the state machine
somewhat to make it more clear.

Finally, it serializes the current announcement state so that we
usually know when we need to send a new update_channel.
lightning/src/ln/channel.rs
lightning/src/ln/channelmanager.rs
lightning/src/ln/functional_tests.rs