Implement on-demand pruning operation

This commit is contained in:
Michael Sproul
2022-09-09 12:56:27 +10:00
parent 69d54741c1
commit d5adc2ebc5
2 changed files with 99 additions and 1 deletions

View File

@@ -266,6 +266,11 @@ where
self.genesis_time = Some(genesis_state.genesis_time());
// Prune finalized execution payloads.
store
.try_prune_execution_payloads(false)
.map_err(|e| format!("Error pruning execution payloads: {e:?}"))?;
self.op_pool = Some(
store
.get_item::<PersistedOperationPool<TEthSpec>>(&OP_POOL_DB_KEY)