X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Fchain%2Fchaininterface.rs;h=2e37127e038548ebe86888e185f52af1b9264551;hb=71fef35eb26c434d896998e3b482d295db89ee22;hp=1f42dc2fe4251a26be3c7b659bae89505893b6e3;hpb=4b35697aff5af6bb505f4fc8b21bc56b966e8274;p=rust-lightning diff --git a/lightning/src/chain/chaininterface.rs b/lightning/src/chain/chaininterface.rs index 1f42dc2f..2e37127e 100644 --- a/lightning/src/chain/chaininterface.rs +++ b/lightning/src/chain/chaininterface.rs @@ -14,7 +14,8 @@ //! disconnections, transaction broadcasting, and feerate information requests. use core::{cmp, ops::Deref}; -use core::convert::TryInto; + +use crate::prelude::*; use bitcoin::blockdata::transaction::Transaction; @@ -123,6 +124,17 @@ pub enum ConfirmationTarget { /// /// [`ChannelManager::close_channel_with_feerate_and_script`]: crate::ln::channelmanager::ChannelManager::close_channel_with_feerate_and_script ChannelCloseMinimum, + /// The feerate [`OutputSweeper`] will use on transactions spending + /// [`SpendableOutputDescriptor`]s after a channel closure. + /// + /// Generally spending these outputs is safe as long as they eventually confirm, so a value + /// (slightly above) the mempool minimum should suffice. However, as this value will influence + /// how long funds will be unavailable after channel closure, [`FeeEstimator`] implementors + /// might want to choose a higher feerate to regain control over funds faster. + /// + /// [`OutputSweeper`]: crate::util::sweep::OutputSweeper + /// [`SpendableOutputDescriptor`]: crate::sign::SpendableOutputDescriptor + OutputSpendingFee, } /// A trait which should be implemented to provide feerate information on a number of time