channeldb: add migration to properly prune edge update index
In this commit, we introduce a migration to fix some of the recent issues found w.r.t. the edge update index. The migration attempts to fix two things: 1) Edge policies include an extra byte at the end due to reading an extra byte for the node's public key from the serialized node info. 2) Properly prune all stale entries within the edge update index. As a result of this migration, nodes will have a slightly smaller in size channeldb. We will also no longer send stale edges to our peers in response to their gossip queries, which should also fix the fetching channel announcement for closed channels issue.
This commit is contained in:
2 files changed
+111
No files matched your search
@@ -74,6 +74,12 @@ var (
|
||||
number: 5,
|
||||
migration: paymentStatusesMigration,
|
||||
},
|
||||
{
|
||||
// The DB version that properly prunes stale entries
|
||||
// from the edge update index.
|
||||
number: 6,
|
||||
migration: migratePruneEdgeUpdateIndex,
|
||||
},
|
||||
}
|
||||
|
||||
// Big endian is the preferred byte order, due to cursor scans over
|
||||
|
||||
Reference in new issue
Block a user