Skip to main content

create_fee_history_cache_item

Function create_fee_history_cache_item 

Source
pub(crate) fn create_fee_history_cache_item<N: Network>(
    hash: B256,
    header: &impl BlockHeader,
    storage_info: &StorageInfo<N>,
    blob_params: BlobParams,
) -> (FeeHistoryCacheItem, Option<u64>)
where N::ReceiptEnvelope: TxReceipt<Log = Log>,
Expand description

Builds the FeeHistoryCacheItem for a single block.

Shared by the async FeeHistoryService and by eth_feeHistory itself: the service can lag the chain head (it only runs when the node task is polled), so the RPC handler computes any missing entry on demand with the same logic instead of returning a short response.