reth_db_common::init

Function init_from_state_dump

Source
pub fn init_from_state_dump<Provider>(
    reader: impl BufRead,
    provider_rw: &Provider,
    etl_config: EtlConfig,
) -> Result<B256>
Expand description

Reads account state from a BufRead reader and initializes it at the highest block that can be found on database.

It’s similar to init_genesis but supports importing state too big to fit in memory, and can be set to the highest block present. One practical usecase is to import OP mainnet state at bedrock transition block.