/// An unbroadcasted batch funding transaction id. The closure of this channel should be
/// propagated to the remainder of the batch.
pub(crate) unbroadcasted_batch_funding_txid: Option<Txid>,
+ pub(crate) channel_id: ChannelId,
+ pub(crate) counterparty_node_id: PublicKey,
}
/// If the majority of the channels funds are to the fundee and the initiator holds only just
monitor_update,
dropped_outbound_htlcs,
unbroadcasted_batch_funding_txid,
+ channel_id: self.channel_id,
+ counterparty_node_id: self.counterparty_node_id,
}
}
monitor_update: None,
dropped_outbound_htlcs: Vec::new(),
unbroadcasted_batch_funding_txid: self.context.unbroadcasted_batch_funding_txid(),
+ channel_id: self.context.channel_id,
+ counterparty_node_id: self.context.counterparty_node_id,
};
let tx = self.build_signed_closing_transaction(&mut closing_tx, &msg.signature, &sig);
self.context.channel_state = ChannelState::ShutdownComplete as u32;
monitor_update: None,
dropped_outbound_htlcs: Vec::new(),
unbroadcasted_batch_funding_txid: self.context.unbroadcasted_batch_funding_txid(),
+ channel_id: self.context.channel_id,
+ counterparty_node_id: self.context.counterparty_node_id,
};
self.context.channel_state = ChannelState::ShutdownComplete as u32;
self.context.update_time_counter += 1;
monitor_update: None,
dropped_outbound_htlcs: Vec::new(),
unbroadcasted_batch_funding_txid: self.context.unbroadcasted_batch_funding_txid(),
+ channel_id: self.context.channel_id,
+ counterparty_node_id: self.context.counterparty_node_id,
};
self.context.channel_state = ChannelState::ShutdownComplete as u32;
Some(shutdown_result)
debug_assert_ne!(peer.held_by_thread(), LockHeldState::HeldByThread);
}
- log_debug!(self.logger, "Finishing closure of channel with {} HTLCs to fail", shutdown_res.dropped_outbound_htlcs.len());
+ let logger = WithContext::from(
+ &self.logger, Some(shutdown_res.counterparty_node_id), Some(shutdown_res.channel_id),
+ );
+ log_debug!(logger, "Finishing closure of channel with {} HTLCs to fail", shutdown_res.dropped_outbound_htlcs.len());
for htlc_source in shutdown_res.dropped_outbound_htlcs.drain(..) {
let (source, payment_hash, counterparty_node_id, channel_id) = htlc_source;
let reason = HTLCFailReason::from_failure_code(0x4000 | 8);