lnd.xprv/routing
Olaoluwa Osuntokun 93b04b39fe
routing: account for remaining routing onion errors in SendPayment
In this commit, we address a number of edge cases that were unaccounted
for when responding to errors that can be sent back due to an HTLC
routing failure. Namely:

   * We’ll no longer stop payment attempts if we’re unable to apply a
channel update, instead, we’ll log the error, prune the channel and
continue.
    * We’ll no remember which channels were pruned due to insufficient
fee errors. If we ever get a repeat fee error from a channel, then we
prune it. This ensure that we don’t get stuck in a loop due to a node
continually advertising the same fees.
   * We also correct an error in which node we’d prune due to a
temporary or permanent node failure. Before this commit, we would prune
the next node, when we should actually be pruning the node that sent us
the error.

Finally, we also add a new test to exercise the fee insufficient error
handling and channel pruning.

Fixes #865.
2018-03-21 15:23:48 -07:00
..
chainview routing/chainview: bitcoind back-end now requires explicit NotifyBlocks() 2018-03-14 12:16:40 -06:00
testdata routing: weight findPath more heavily towards fees during edge relaxation 2018-02-12 16:27:38 -08:00
errors.go routing: add new PayAttemptTimeout field to LightningPayment 2018-03-21 15:23:45 -07:00
graph.go routing: rewrite package to conform to BOLT07 and factor in fees+timelocks 2016-12-27 16:44:22 -08:00
heap_test.go routing: correct recent type change in heap_test.go 2018-02-12 16:44:42 -08:00
heap.go routing: weight findPath more heavily towards fees during edge relaxation 2018-02-12 16:27:38 -08:00
log.go lnd: remove seelog logger 2017-06-25 14:19:56 +01:00
missioncontrol.go routing: update package to account for recent channeldb API changes 2018-02-06 20:14:32 -08:00
notifications_test.go routing: update package to account for recent channeldb API changes 2018-02-06 20:14:32 -08:00
notifications.go routing: update package to account for recent channeldb API changes 2018-02-06 20:14:32 -08:00
pathfind_test.go routing: weight findPath more heavily towards fees during edge relaxation 2018-02-12 16:27:38 -08:00
pathfind.go build+multi: switch from bolt to bbolt 2018-03-10 19:01:13 -08:00
README.md multi: fix formatting issues in packge README's 2017-03-27 16:25:25 -07:00
router_test.go routing: account for remaining routing onion errors in SendPayment 2018-03-21 15:23:48 -07:00
router.go routing: account for remaining routing onion errors in SendPayment 2018-03-21 15:23:48 -07:00
validation_barrier.go routing: extract zombie pruning to distinct method 2018-02-06 20:14:34 -08:00

routing

Build Status MIT licensed GoDoc

The routing package implements authentication+validation of channel announcements, pruning of the channel graph, path finding within the network, sending outgoing payments into the network and synchronizing new peers to our channel graph state.

Installation and Updating

$ go get -u github.com/lightningnetwork/lnd/routing