]> git.bitcoin.ninja Git - rust-lightning/commit
Add a method to prune stale channels from `NetworkGraph`
authorMatt Corallo <git@bluematt.me>
Fri, 10 Dec 2021 06:46:29 +0000 (06:46 +0000)
committerMatt Corallo <git@bluematt.me>
Thu, 16 Dec 2021 18:33:24 +0000 (18:33 +0000)
commit4677e14c007a5453613afc20b088cbe938251226
tree7859773ab7ad203700fae1967c168abc48538fb6
parentc575429639a388ef3d5fc2b036163914bc947c57
Add a method to prune stale channels from `NetworkGraph`

We define "stale" as "haven't heard an updated channel_update in
two weeks", as described in BOLT 7.

We also filter out stale channels at write-time for `std` users, as
we can look up the current time.
lightning/src/routing/network_graph.rs