Function cuprate_txpool::service::init

source ·
pub fn init(
    config: Config,
) -> Result<(TxpoolReadHandle, TxpoolWriteHandle, Arc<ConcreteEnv>), InitError>
Expand description

Initialize a database & thread-pool, and return a read/write handle to it.

Once the returned handles are Drop::droped, the reader thread-pool and writer thread will exit automatically.

§Errors

This will forward the error if crate::open failed.