only consider top level highest dir name on archive node file root; also added back hlfs to blockingest struct

This commit is contained in:
Nicholas Wehr
2025-08-26 19:49:45 -07:00
parent e8be4c2e82
commit 738567894a
3 changed files with 19 additions and 7 deletions

View File

@ -29,6 +29,7 @@ use tokio::sync::Mutex;
use tracing::{debug, info};
use crate::serialized::{BlockAndReceipts, EvmBlock};
use crate::share_blocks::ShareBlocks;
use crate::spot_meta::erc20_contract_to_spot_token;
/// Poll interval when tailing an *open* hourly file.
@ -41,6 +42,7 @@ pub(crate) struct BlockIngest {
pub local_ingest_dir: Option<PathBuf>,
pub local_blocks_cache: Arc<Mutex<BTreeMap<u64, BlockAndReceipts>>>, // height → block
pub precompiles_cache: PrecompilesCache,
pub hlfs: Option<ShareBlocks>,
}
#[derive(Deserialize)]

View File

@ -54,12 +54,12 @@ impl ShareBlocks {
}
});
let _autodetect = spawn_autodetect(network, host, args.share_blocks_port, args.archive_dir.clone());
let _autodetect =
spawn_autodetect(network, host, args.share_blocks_port, args.archive_dir.clone());
info!(%bind, dir=%args.archive_dir.display(), "hlfs: enabled (reth peers)");
Ok(Self { _server, _autodetect })
}
}
fn spawn_autodetect<Net>(