watchtower: build channel to sessionIDs index
In this commit, a migration is added that adds an index from channel to sessionIDs (using the DB-assigned session IDs). This will make it easier in future to know which sessions have updates for which channels.
This commit is contained in:
7 files changed
+485
-1
No files matched your search
@@ -11,6 +11,7 @@ import (
|
||||
"github.com/lightningnetwork/lnd/watchtower/wtdb/migration4"
|
||||
"github.com/lightningnetwork/lnd/watchtower/wtdb/migration5"
|
||||
"github.com/lightningnetwork/lnd/watchtower/wtdb/migration6"
|
||||
"github.com/lightningnetwork/lnd/watchtower/wtdb/migration7"
|
||||
)
|
||||
|
||||
// txMigration is a function which takes a prior outdated version of the
|
||||
@@ -63,6 +64,9 @@ var clientDBVersions = []version{
|
||||
{
|
||||
txMigration: migration6.MigrateSessionIDIndex,
|
||||
},
|
||||
{
|
||||
txMigration: migration7.MigrateChannelToSessionIndex,
|
||||
},
|
||||
}
|
||||
|
||||
// getLatestDBVersion returns the last known database version.
|
||||
|
||||
Reference in new issue
Block a user