mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-20 14:28:37 +00:00
Implement ERA consumer and producer in lcli
This commit is contained in:
@@ -2076,6 +2076,17 @@ impl<E: EthSpec, Hot: ItemStore<E>, Cold: ItemStore<E>> HotColdDB<E, Hot, Cold>
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Store a pre-finalization state in the freezer database, applying ops atomically.
|
||||
pub fn put_cold_state(
|
||||
&self,
|
||||
state_root: &Hash256,
|
||||
state: &BeaconState<E>,
|
||||
) -> Result<(), Error> {
|
||||
let mut ops: Vec<KeyValueStoreOp> = Vec::new();
|
||||
self.store_cold_state(state_root, state, &mut ops)?;
|
||||
self.cold_db.do_atomically(ops)
|
||||
}
|
||||
|
||||
/// Store a pre-finalization state in the freezer database.
|
||||
pub fn store_cold_state(
|
||||
&self,
|
||||
|
||||
Reference in New Issue
Block a user