mirror of
https://github.com/status-im/nimbus-eth2.git
synced 2025-01-20 11:29:51 +00:00
change db key
This commit is contained in:
parent
4bd6ead294
commit
b6e89eb7e3
@ -115,7 +115,7 @@ type
|
|||||||
blocks: array[ConsensusFork, KvStoreRef] # BlockRoot -> TrustedSignedBeaconBlock
|
blocks: array[ConsensusFork, KvStoreRef] # BlockRoot -> TrustedSignedBeaconBlock
|
||||||
|
|
||||||
blobs: KvStoreRef # (BlockRoot -> BlobSidecar)
|
blobs: KvStoreRef # (BlockRoot -> BlobSidecar)
|
||||||
|
columns: KvStoreRef # (BlockRoot -> DataColumnSidecar)
|
||||||
stateRoots: KvStoreRef # (Slot, BlockRoot) -> StateRoot
|
stateRoots: KvStoreRef # (Slot, BlockRoot) -> StateRoot
|
||||||
|
|
||||||
statesNoVal: array[ConsensusFork, KvStoreRef] # StateRoot -> ForkBeaconStateNoImmutableValidators
|
statesNoVal: array[ConsensusFork, KvStoreRef] # StateRoot -> ForkBeaconStateNoImmutableValidators
|
||||||
@ -1094,11 +1094,11 @@ proc getDataColumnSidecarSZ*(db: BeaconChainDB, root: Eth2Digest,
|
|||||||
let dataPtr = addr data # Short-lived
|
let dataPtr = addr data # Short-lived
|
||||||
func decode(data: openArray[byte]) =
|
func decode(data: openArray[byte]) =
|
||||||
assign(dataPtr[], data)
|
assign(dataPtr[], data)
|
||||||
db.blobs.get(columnkey(root, index), decode).expectDb()
|
db.columns.get(columnkey(root, index), decode).expectDb()
|
||||||
|
|
||||||
proc getDataColumnSidecar*(db: BeaconChainDB, root: Eth2Digest, index: ColumnIndex,
|
proc getDataColumnSidecar*(db: BeaconChainDB, root: Eth2Digest, index: ColumnIndex,
|
||||||
value: var DataColumnSidecar): bool =
|
value: var DataColumnSidecar): bool =
|
||||||
db.blobs.getSZSSZ(columnkey(root, index), value) == GetResult.found
|
db.columns.getSZSSZ(columnkey(root, index), value) == GetResult.found
|
||||||
|
|
||||||
proc getBlockSZ*(
|
proc getBlockSZ*(
|
||||||
db: BeaconChainDB, key: Eth2Digest, data: var seq[byte],
|
db: BeaconChainDB, key: Eth2Digest, data: var seq[byte],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user