reth_provider/providers/
mod.rs1use reth_chainspec::EthereumHardforks;
4use reth_db_api::table::Value;
5use reth_node_types::{NodePrimitives, NodeTypes, NodeTypesWithDB};
6
7mod database;
8pub use database::*;
9
10mod static_file;
11pub use static_file::{
12 StaticFileAccess, StaticFileJarProvider, StaticFileProvider, StaticFileProviderBuilder,
13 StaticFileProviderRW, StaticFileProviderRWRefMut, StaticFileWriteCtx, StaticFileWriter,
14};
15
16mod state;
17pub use state::{
18 historical::{
19 compute_history_rank, history_info, needs_prev_shard_check, HistoricalStateProvider,
20 HistoricalStateProviderRef, HistoryInfo, LowestAvailableBlocks,
21 },
22 latest::{LatestStateProvider, LatestStateProviderRef},
23};
24
25mod blockchain_provider;
26pub use blockchain_provider::{BlockchainProvider, SNAPSHOT_STATE_RETENTION};
27
28mod consistent;
29pub use consistent::ConsistentProvider;
30
31pub(crate) mod rocksdb;
32
33pub use rocksdb::{
34 PruneShardOutcome, PrunedIndices, RocksDBBatch, RocksDBBuilder, RocksDBIter, RocksDBProvider,
35 RocksDBRawIter, RocksDBStats, RocksDBTableStats, RocksReadSnapshot, RocksTx,
36};
37
38pub trait NodeTypesForProvider
41where
42 Self: NodeTypes<
43 ChainSpec: EthereumHardforks,
44 Storage: ChainStorage<Self::Primitives>,
45 Primitives: NodePrimitives<SignedTx: Value, Receipt: Value, BlockHeader: Value>,
46 >,
47{
48}
49
50impl<T> NodeTypesForProvider for T where
51 T: NodeTypes<
52 ChainSpec: EthereumHardforks,
53 Storage: ChainStorage<T::Primitives>,
54 Primitives: NodePrimitives<SignedTx: Value, Receipt: Value, BlockHeader: Value>,
55 >
56{
57}
58
59pub trait ProviderNodeTypes
61where
62 Self: NodeTypesForProvider + NodeTypesWithDB,
63{
64}
65impl<T> ProviderNodeTypes for T where T: NodeTypesForProvider + NodeTypesWithDB {}