add column support fully to db
This commit is contained in:
parent
1ba8948466
commit
8c2fdecc4e
|
@ -557,8 +557,10 @@ proc new*(T: type BeaconChainDB,
|
||||||
static: doAssert LightClientDataFork.high == LightClientDataFork.Deneb
|
static: doAssert LightClientDataFork.high == LightClientDataFork.Deneb
|
||||||
|
|
||||||
var blobs : KvStoreRef
|
var blobs : KvStoreRef
|
||||||
|
var columns : KvStoreRef
|
||||||
if cfg.DENEB_FORK_EPOCH != FAR_FUTURE_EPOCH:
|
if cfg.DENEB_FORK_EPOCH != FAR_FUTURE_EPOCH:
|
||||||
blobs = kvStore db.openKvStore("deneb_blobs").expectDb()
|
# blobs = kvStore db.openKvStore("deneb_blobs").expectDb()
|
||||||
|
columns = kvStore db.openKvStore("deneb_columns").expectDb()
|
||||||
|
|
||||||
# Versions prior to 1.4.0 (altair) stored validators in `immutable_validators`
|
# Versions prior to 1.4.0 (altair) stored validators in `immutable_validators`
|
||||||
# which stores validator keys in compressed format - this is
|
# which stores validator keys in compressed format - this is
|
||||||
|
@ -595,6 +597,7 @@ proc new*(T: type BeaconChainDB,
|
||||||
keyValues: keyValues,
|
keyValues: keyValues,
|
||||||
blocks: blocks,
|
blocks: blocks,
|
||||||
blobs: blobs,
|
blobs: blobs,
|
||||||
|
columns: columns,
|
||||||
stateRoots: stateRoots,
|
stateRoots: stateRoots,
|
||||||
statesNoVal: statesNoVal,
|
statesNoVal: statesNoVal,
|
||||||
stateDiffs: stateDiffs,
|
stateDiffs: stateDiffs,
|
||||||
|
@ -764,6 +767,8 @@ proc close*(db: BeaconChainDB) =
|
||||||
# Close things roughly in reverse order
|
# Close things roughly in reverse order
|
||||||
if not isNil(db.blobs):
|
if not isNil(db.blobs):
|
||||||
discard db.blobs.close()
|
discard db.blobs.close()
|
||||||
|
if not isNil(db.columns):
|
||||||
|
discard db.columns.close()
|
||||||
db.lcData.close()
|
db.lcData.close()
|
||||||
db.finalizedBlocks.close()
|
db.finalizedBlocks.close()
|
||||||
discard db.summaries.close()
|
discard db.summaries.close()
|
||||||
|
|
Loading…
Reference in New Issue