feat(storage): replace Tree generic with Arc<dyn TreeViewer> (#7810)

Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de>
This commit is contained in:
Kyrylo Riabov
2024-04-23 22:10:45 +03:00
committed by GitHub
parent a8a434d2c4
commit c659e28aa0
9 changed files with 102 additions and 113 deletions

View File

@ -136,11 +136,10 @@ impl Command {
EvmProcessorFactory::new(self.chain.clone(), evm_config),
);
let tree = BlockchainTree::new(tree_externals, BlockchainTreeConfig::default(), None)?;
let blockchain_tree = ShareableBlockchainTree::new(tree);
let blockchain_tree = Arc::new(ShareableBlockchainTree::new(tree));
// Set up the blockchain provider
let blockchain_db =
BlockchainProvider::new(provider_factory.clone(), blockchain_tree.clone())?;
let blockchain_db = BlockchainProvider::new(provider_factory.clone(), blockchain_tree)?;
// Set up network
let network_secret_path =