multi: move active/inactive ntfns from switch to link
Since we will now wait to deliver the event after channel reestablish, notifying when the link is added to the switch will no longer be sufficient. Later, we will add receiving reestablish as an additional requirement for EligibleToForward returning true. The inactive ntfn is also moved, to ensure that we don't fire inactive notifications if no corresponding active notification was sent.
This commit is contained in:
7 files changed
+28
-21
No files matched your search
@@ -430,8 +430,6 @@ func newServer(listenAddrs []net.Addr, chanDB *channeldb.DB,
|
||||
FwdEventTicker: ticker.New(htlcswitch.DefaultFwdEventInterval),
|
||||
LogEventTicker: ticker.New(htlcswitch.DefaultLogInterval),
|
||||
AckEventTicker: ticker.New(htlcswitch.DefaultAckInterval),
|
||||
NotifyActiveChannel: s.channelNotifier.NotifyActiveChannelEvent,
|
||||
NotifyInactiveChannel: s.channelNotifier.NotifyInactiveChannelEvent,
|
||||
RejectHTLC: cfg.RejectHTLC,
|
||||
}, uint32(currentHeight))
|
||||
if err != nil {
|
||||
|
||||
Reference in new issue
Block a user