diff --git a/src/eth/storage/hybrid/hybrid_state.rs b/src/eth/storage/hybrid/hybrid_state.rs index 72fcb575f..b6df91ea3 100644 --- a/src/eth/storage/hybrid/hybrid_state.rs +++ b/src/eth/storage/hybrid/hybrid_state.rs @@ -68,7 +68,6 @@ pub struct HybridStorageState { pub blocks_by_number: Arc>, pub blocks_by_hash: Arc>, pub logs: Arc>, - pub metadata: Arc>, } impl HybridStorageState { @@ -82,7 +81,6 @@ impl HybridStorageState { blocks_by_number: Arc::new(RocksDb::new("./data/blocks_by_number.rocksdb", DbConfig::LargeSSTFiles).unwrap()), blocks_by_hash: Arc::new(RocksDb::new("./data/blocks_by_hash.rocksdb", DbConfig::LargeSSTFiles).unwrap()), //XXX this is not needed we can afford to have blocks_by_hash pointing into blocks_by_number logs: Arc::new(RocksDb::new("./data/logs.rocksdb", DbConfig::LargeSSTFiles).unwrap()), - metadata: Arc::new(RocksDb::new("./data/metadata.rocksdb", DbConfig::Default).unwrap()), } } diff --git a/src/eth/storage/hybrid/mod.rs b/src/eth/storage/hybrid/mod.rs index 6fe2afdc5..89cfe2960 100644 --- a/src/eth/storage/hybrid/mod.rs +++ b/src/eth/storage/hybrid/mod.rs @@ -388,14 +388,10 @@ impl PermanentStorage for HybridPermanentStorage { let hash = block.hash().clone(); let blocks_by_number = Arc::clone(&self.state.blocks_by_number); - let metadata = Arc::clone(&self.state.metadata); let blocks_by_hash = Arc::clone(&self.state.blocks_by_hash); let block_clone = block.clone(); let hash_clone = hash.clone(); futures.push(tokio::task::spawn_blocking(move || blocks_by_number.insert(number, block_clone))); - futures.push(tokio::task::spawn_blocking(move || { - metadata.insert("current_block_number".to_string(), number.as_u64().to_string()); - })); futures.push(tokio::task::spawn_blocking(move || blocks_by_hash.insert(hash_clone, number))); futures.append(