LSM: Rework snapshot-converter into a command tree (#2064)
Rework the snapshot-converter into a command tree:
- daemon: watch a node's snapshot directory and convert each exported
LSM
snapshot into a Mem snapshot as it is produced
- convert: one-shot conversion between an exported LSM snapshot and a
Mem
snapshot, in either direction
- lsm export / lsm import: move snapshots out of / into an offline LSM
database
Conversions operate only on standalone (exported) LSM snapshots and Mem
snapshots, never on a live database.
db-analyser surfaces the LSM snapshot export directory via a new
'mkLSMConfig'
method on 'HasProtocolInfo' (read from the node config's
'LedgerDB.LSMExportPath'); it keeps using a random salt, as it builds a
throwaway ledger database whose exported snapshots record their own
salt.