Skip to content

Commit 475bee2

Browse files
authored
Merge pull request #326 from TheBlueMatt/2019-03-temp-failure-use-cases
Update docs for TemporaryFailure to note other use-cases
2 parents 91dc91f + b031bdf commit 475bee2

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/ln/channelmonitor.rs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ use std::{hash,cmp, mem};
4848
/// An error enum representing a failure to persist a channel monitor update.
4949
#[derive(Clone)]
5050
pub enum ChannelMonitorUpdateErr {
51-
/// Used to indicate a temporary failure (eg connection to a watchtower failed, but is expected
52-
/// to succeed at some point in the future).
51+
/// Used to indicate a temporary failure (eg connection to a watchtower or remote backup of
52+
/// our state failed, but is expected to succeed at some point in the future).
5353
///
5454
/// Such a failure will "freeze" a channel, preventing us from revoking old states or
5555
/// submitting new commitment transactions to the remote party.
@@ -71,6 +71,10 @@ pub enum ChannelMonitorUpdateErr {
7171
/// Note that even if updates made after TemporaryFailure succeed you must still call
7272
/// test_restore_channel_monitor to ensure you have the latest monitor and re-enable normal
7373
/// channel operation.
74+
///
75+
/// For deployments where a copy of ChannelMonitors and other local state are backed up in a
76+
/// remote location (with local copies persisted immediately), it is anticipated that all
77+
/// updates will return TemporaryFailure until the remote copies could be updated.
7478
TemporaryFailure,
7579
/// Used to indicate no further channel monitor updates will be allowed (eg we've moved on to a
7680
/// different watchtower and cannot update with all watchtowers that were previously informed

0 commit comments

Comments
 (0)