mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-22 15:57:49 +02:00
cnct: simplify channel arbitrator state logging
This commit is contained in:
@@ -850,28 +850,24 @@ func (c *ChannelArbitrator) stateStep(
|
|||||||
// We are waiting for a commitment to be confirmed, so any
|
// We are waiting for a commitment to be confirmed, so any
|
||||||
// other trigger will be ignored.
|
// other trigger will be ignored.
|
||||||
case chainTrigger, userTrigger:
|
case chainTrigger, userTrigger:
|
||||||
log.Infof("ChannelArbitrator(%v): noop trigger %v",
|
|
||||||
c.cfg.ChanPoint, trigger)
|
|
||||||
nextState = StateCommitmentBroadcasted
|
nextState = StateCommitmentBroadcasted
|
||||||
|
|
||||||
// If this state advance was triggered by any of the
|
// If this state advance was triggered by any of the
|
||||||
// commitments being confirmed, then we'll jump to the state
|
// commitments being confirmed, then we'll jump to the state
|
||||||
// where the contract has been closed.
|
// where the contract has been closed.
|
||||||
case localCloseTrigger, remoteCloseTrigger:
|
case localCloseTrigger, remoteCloseTrigger:
|
||||||
log.Infof("ChannelArbitrator(%v): trigger %v, "+
|
|
||||||
" going to StateContractClosed",
|
|
||||||
c.cfg.ChanPoint, trigger)
|
|
||||||
nextState = StateContractClosed
|
nextState = StateContractClosed
|
||||||
|
|
||||||
// If a coop close or breach was confirmed, jump straight to
|
// If a coop close or breach was confirmed, jump straight to
|
||||||
// the fully resolved state.
|
// the fully resolved state.
|
||||||
case coopCloseTrigger, breachCloseTrigger:
|
case coopCloseTrigger, breachCloseTrigger:
|
||||||
log.Infof("ChannelArbitrator(%v): trigger %v, "+
|
|
||||||
" going to StateFullyResolved",
|
|
||||||
c.cfg.ChanPoint, trigger)
|
|
||||||
nextState = StateFullyResolved
|
nextState = StateFullyResolved
|
||||||
}
|
}
|
||||||
|
|
||||||
|
log.Infof("ChannelArbitrator(%v): trigger %v moving from "+
|
||||||
|
"state %v to %v", c.cfg.ChanPoint, trigger, c.state,
|
||||||
|
nextState)
|
||||||
|
|
||||||
// If we're in this state, then the contract has been fully closed to
|
// If we're in this state, then the contract has been fully closed to
|
||||||
// outside sub-systems, so we'll process the prior set of on-chain
|
// outside sub-systems, so we'll process the prior set of on-chain
|
||||||
// contract actions and launch a set of resolvers.
|
// contract actions and launch a set of resolvers.
|
||||||
|
Reference in New Issue
Block a user