channeldb/migration13: migrate to mpp structure

This commit migrates the payments in the database to a new structure
that allows for multiple htlcs per payments. The migration introduces a
new sub-bucket that contains a list of htlcs and moves the old single
htlc into that.
This commit is contained in:
Joost Jager
2020-02-20 18:08:01 +01:00
parent 4cea2d5213
commit 866623e84b
5 changed files with 347 additions and 0 deletions

View File

@@ -4,6 +4,7 @@ import (
"github.com/btcsuite/btclog"
"github.com/lightningnetwork/lnd/build"
"github.com/lightningnetwork/lnd/channeldb/migration12"
"github.com/lightningnetwork/lnd/channeldb/migration13"
"github.com/lightningnetwork/lnd/channeldb/migration_01_to_11"
)
@@ -29,4 +30,5 @@ func UseLogger(logger btclog.Logger) {
log = logger
migration_01_to_11.UseLogger(logger)
migration12.UseLogger(logger)
migration13.UseLogger(logger)
}