watchtower/wtdb: add new towerID-to-sessionID index
This commit adds a new towerID-to-sessionID index to the wtclient DB. The commit also contains the necessary migration required in order to build the index for an existing client. This index will greatly improve the lookup of sessions for a given tower ID.
This commit is contained in:
7 files changed
+620
-2
No files matched your search
@@ -3,6 +3,7 @@ package wtdb
|
||||
import (
|
||||
"github.com/btcsuite/btclog"
|
||||
"github.com/lightningnetwork/lnd/build"
|
||||
"github.com/lightningnetwork/lnd/watchtower/wtdb/migration1"
|
||||
)
|
||||
|
||||
// log is a logger that is initialized with no output filters. This
|
||||
@@ -26,6 +27,7 @@ func DisableLog() {
|
||||
// using btclog.
|
||||
func UseLogger(logger btclog.Logger) {
|
||||
log = logger
|
||||
migration1.UseLogger(logger)
|
||||
}
|
||||
|
||||
// logClosure is used to provide a closure over expensive logging operations so
|
||||
|
||||
Reference in new issue
Block a user