routing+channeldb: migrate MC store to use minimal Route encoding
Add a new mcRoute type that houses the data about a route that MC actually uses. Then add a migration (channeldb/migration32) that migrates the existing store from its current serialisation to the new, more minimal serialisation.
This commit is contained in:
9 files changed
+873
-136
No files matched your search
@@ -18,12 +18,16 @@ const testMaxRecords = 2
|
||||
|
||||
var (
|
||||
// mcStoreTestRoute is a test route for the mission control store tests.
|
||||
mcStoreTestRoute = route.Route{
|
||||
SourcePubKey: route.Vertex{1},
|
||||
Hops: []*route.Hop{
|
||||
mcStoreTestRoute = mcRoute{
|
||||
totalAmount: lnwire.MilliSatoshi(5),
|
||||
sourcePubKey: route.Vertex{1},
|
||||
hops: []*mcHop{
|
||||
{
|
||||
PubKeyBytes: route.Vertex{2},
|
||||
LegacyPayload: true,
|
||||
pubKeyBytes: route.Vertex{2},
|
||||
channelID: 4,
|
||||
amtToFwd: lnwire.MilliSatoshi(7),
|
||||
hasCustomRecords: true,
|
||||
hasBlindingPoint: false,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user