multi: add the flag prune-revocation to perform the optional migration
This commit is contained in:
3 files changed
+9
No files matched your search
@@ -857,6 +857,7 @@ func (d *DefaultDatabaseBuilder) BuildDatabase(
|
|||||||
channeldb.OptionDryRunMigration(cfg.DryRunMigration),
|
channeldb.OptionDryRunMigration(cfg.DryRunMigration),
|
||||||
channeldb.OptionSetUseGraphCache(!cfg.DB.NoGraphCache),
|
channeldb.OptionSetUseGraphCache(!cfg.DB.NoGraphCache),
|
||||||
channeldb.OptionKeepFailedPaymentAttempts(cfg.KeepFailedPaymentAttempts),
|
channeldb.OptionKeepFailedPaymentAttempts(cfg.KeepFailedPaymentAttempts),
|
||||||
|
channeldb.OptionPruneRevocationLog(cfg.DB.PruneRevocation),
|
||||||
}
|
}
|
||||||
|
|
||||||
// We want to pre-allocate the channel graph cache according to what we
|
// We want to pre-allocate the channel graph cache according to what we
|
||||||
|
|||||||
@@ -61,6 +61,8 @@ type DB struct {
|
|||||||
Postgres *postgres.Config `group:"postgres" namespace:"postgres" description:"Postgres settings."`
|
Postgres *postgres.Config `group:"postgres" namespace:"postgres" description:"Postgres settings."`
|
||||||
|
|
||||||
NoGraphCache bool `long:"no-graph-cache" description:"Don't use the in-memory graph cache for path finding. Much slower but uses less RAM. Can only be used with a bolt database backend."`
|
NoGraphCache bool `long:"no-graph-cache" description:"Don't use the in-memory graph cache for path finding. Much slower but uses less RAM. Can only be used with a bolt database backend."`
|
||||||
|
|
||||||
|
PruneRevocation bool `long:"prune-revocation" description:"Run the optional migration that prunes the revocation logs to save disk space."`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DefaultDB creates and returns a new default DB config.
|
// DefaultDB creates and returns a new default DB config.
|
||||||
|
|||||||
@@ -1205,6 +1205,12 @@ litecoin.node=ltcd
|
|||||||
; less RAM. Can only be used with a bolt database backend.
|
; less RAM. Can only be used with a bolt database backend.
|
||||||
; db.no-graph-cache=true
|
; db.no-graph-cache=true
|
||||||
|
|
||||||
|
; Specify whether the optional migration for pruning old revocation logs
|
||||||
|
; should be applied. This migration will only save disk space if there are open
|
||||||
|
; channels prior to lnd@v0.15.0.
|
||||||
|
; db.prune-revocation=false
|
||||||
|
|
||||||
|
|
||||||
[etcd]
|
[etcd]
|
||||||
|
|
||||||
; Etcd database host.
|
; Etcd database host.
|
||||||
|
|||||||
Reference in new issue
Block a user