-
Notifications
You must be signed in to change notification settings - Fork 890
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Permuteroute #2890
Permuteroute #2890
Conversation
Article on |
I gave it a look and especially to integrate it in |
Yes, that is approximately what is needed. Some subtleties:
|
f17c5f4
to
072e815
Compare
Test passing whee! |
…ute. Will be reused later for `permuteroute` results too.
… and `erring_index`.
676fa65
to
9ba5ba5
Compare
…pt just after a failed `sendpay`.
Re-marking as WIP. I am reconceptualizing the search algorithm, as the current naive depth-first search algorithm is likely to rescan the same nodes over and over when at nodes with many channels. Sketch:
|
This lets us reuse the same scratch space for other search algorithms.
Tweaked algorithm seems good. I need help with someone who can run a mainnet node to compare |
In general, I prefer to adapt new low-level commands and do fancy things in plugins. route permutation can be done by asking to route from the node before the erroring channel to a node afterwards. That's currently no more efficient than doing a complete new route, since we don't limit our Dijkstra (we normally want to know if there's a possible route). Here's a patch which adds that (untested!) though: https://gist.github.com/rustyrussell/3c752686991fb73ce256eefabee2ee2a |
True, but the currently-exposed We also need to somehow expose
In any case I am now working on |
As I noted there, this adds at least 4 bytes to each Now, the reason to limit the number of hops to scan is really to limit the number of nodes to scan, because O(n log n) on number of nodes scanned. So a different thing we can do is to instead a Then we can do some test Then |
Shelved. In favor of #3001 . |
This is a new command/routing heuristic, inspired by @renepickhardt JIT-Routing.
It turns out to be an actual technique used in real-time strategy games (whose pathfinding issues actually surprisingly match that of LN: low acceptable latency for UX, dynamically-changing world, incomplete information (at least the really good games will not let your units know the "real" state of the world, only what your fog-of-war knows), large maps).
I will be posting a very lengthy article on lightning-dev mailinglist regarding permuteroute and other heuristics inspired by real-time strategy game techniques.
This is incomplete. Help wanted.
permuteroute
, especially for route smoothing (i.e. backing out of a node when all alternatives are excluded).pay
plugin to usepermuteroute
and fall back ongetroute
if failed / too expensive.