mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-07-05 13:02:34 +02:00
htlcswitch: add usage of queue in channel link
In this commit usage of the pending packet queue have been added. This queue will consume the downstream packets if state machine return the error that we do not have enough capacity for htlc in commitment transaction. Upon receiving settle/fail payment descriptors - add htlc have been removed, we release the slot, and process pending add htlc requests.
This commit is contained in:
committed by
Olaoluwa Osuntokun
parent
22d90d6b35
commit
7595bee27c
@ -359,7 +359,7 @@ func (n *threeHopNetwork) makePayment(peers []Peer,
|
||||
select {
|
||||
case err := <-errChan:
|
||||
return invoice, err
|
||||
case <-time.After(6 * time.Second):
|
||||
case <-time.After(12 * time.Second):
|
||||
return invoice, errors.New("htlc was no settled in time")
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user