cuprate_txpool::service

Function 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.