reth_transaction_pool

Type Alias EthTransactionPool

Source
pub type EthTransactionPool<Client, S> = Pool<TransactionValidationTaskExecutor<EthTransactionValidator<Client, EthPooledTransaction>>, CoinbaseTipOrdering<EthPooledTransaction>, S>;
Expand description

Type alias for default ethereum transaction pool

Aliased Type§

struct EthTransactionPool<Client, S> { /* private fields */ }

Implementations§

Source§

impl<Client, S> EthTransactionPool<Client, S>
where Client: StateProviderFactory + Clone + 'static, S: BlobStore,

Source

pub fn eth_pool( validator: TransactionValidationTaskExecutor<EthTransactionValidator<Client, EthPooledTransaction>>, blob_store: S, config: PoolConfig, ) -> Self

Returns a new Pool that uses the default TransactionValidationTaskExecutor when validating EthPooledTransactions and ords via CoinbaseTipOrdering

§Example
use reth_chainspec::MAINNET;
use reth_storage_api::StateProviderFactory;
use reth_tasks::TokioTaskExecutor;
use reth_transaction_pool::{
    blobstore::InMemoryBlobStore, Pool, TransactionValidationTaskExecutor,
};
let blob_store = InMemoryBlobStore::default();
let pool = Pool::eth_pool(
    TransactionValidationTaskExecutor::eth(
        client,
        MAINNET.clone(),
        blob_store.clone(),
        TokioTaskExecutor::default(),
    ),
    blob_store,
    Default::default(),
);

Layout§

Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.

Size: 8 bytes