Proposal for Syncing Channel Updates

Lightning network is a peer to peer network of nodes, each node keeps a graph of the current existing nodes on the network with the nodes as vertices and the channels as edges. The routing table includes information about the channels existing on the network like their fee parameters, channel participants and others.

This information sometimes needs updating and so the node should be in continuous sync with the rest of the network, this syncing needs to be as efficient as possible. The first implementation of this was that nodes would request a complete dump of the routing table of the nodes they are connected to, updating their table with the new information which is a highly impractical way to do things. Then came a different implementation, every node would send its peers a list of channel ids, and the peer would reply back with information about the ids it has but the other participant doesn’t, nodes can also send a timestamp-based filter to their peers and their peers would reply back with updates that match this filter. This works well when the node misses a channel announcement but not when it misses a channel updates.

An update was suggested to include channel update timestamps to the channel range queries, the reply_channel_range will now include 4 bytes of a timestamp and the query_short_channel_ids will include a flag that is set to 1 if the node should send back a channel announcement and the updates, and would otherwise send just the updates.

Support us and the authors of this article by donating to the following address:


Comments powered by Talkyard.