mirror of
https://github.com/status-im/nimbus-eth2.git
synced 2025-01-23 04:50:59 +00:00
store full state 4x less often (#2542)
This commit is contained in:
parent
dd43a2c3b0
commit
1d6c8ee9ab
@ -588,7 +588,7 @@ proc putState*(dag: ChainDAGRef, state: var StateData) =
|
|||||||
dag.db.putState(state.data.root, state.data.data)
|
dag.db.putState(state.data.root, state.data.data)
|
||||||
|
|
||||||
# Allow backwards-compatible version rollback with bounded recovery cost
|
# Allow backwards-compatible version rollback with bounded recovery cost
|
||||||
if getStateField(state, slot).epoch mod 64 == 0:
|
if getStateField(state, slot).epoch mod 256 == 0:
|
||||||
dag.db.putStateFull(state.data.root, state.data.data)
|
dag.db.putStateFull(state.data.root, state.data.data)
|
||||||
|
|
||||||
dag.db.putStateRoot(
|
dag.db.putStateRoot(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user