Skip to content

Commit f8a0c1b

Browse files
committed
removed ugly default
1 parent 52de34f commit f8a0c1b

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

crates/rbuilder/src/live_builder/base_config.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,6 @@ impl BaseConfig {
476476
pub const DEFAULT_CL_NODE_URL: &str = "http://127.0.0.1:3500";
477477
pub const DEFAULT_EL_NODE_IPC_PATH: &str = "/tmp/reth.ipc";
478478
pub const DEFAULT_INCOMING_BUNDLES_PORT: u16 = 8645;
479-
pub const DEFAULT_RETH_DB_PATH: &str = "/mnt/data/reth";
480479
/// This will update every 2.4 hours, super reasonable.
481480
pub const DEFAULT_BLOCKLIST_URL_MAX_AGE_HOURS: u64 = 24;
482481
pub const DEFAULT_REQUIRE_NON_EMPTY_BLOCKLIST: bool = false;
@@ -502,7 +501,7 @@ impl Default for BaseConfig {
502501
ignore_cancellable_orders: true,
503502
ignore_blobs: false,
504503
chain: "mainnet".to_string(),
505-
reth_datadir: Some(DEFAULT_RETH_DB_PATH.parse().unwrap()),
504+
reth_datadir: None,
506505
reth_db_path: None,
507506
reth_static_files_path: None,
508507
reth_rocksdb_path: None,
@@ -565,6 +564,7 @@ pub fn create_provider_factory(
565564
rw: bool,
566565
root_hash_config: Option<RootHashContext>,
567566
) -> eyre::Result<ProviderFactoryReopener<NodeTypesWithDBAdapter<EthereumNode, Arc<DatabaseEnv>>>> {
567+
tracing::info!(?reth_datadir, "AAAAAAAAAAAA!!!!!!!!!");
568568
// shellexpand the reth datadir
569569
let reth_datadir = if let Some(reth_datadir) = reth_datadir {
570570
let reth_datadir = reth_datadir
@@ -596,14 +596,15 @@ pub fn create_provider_factory(
596596
}
597597
};
598598

599-
let reth_rocksdb_path = match (reth_rocksdb_path, reth_datadir) {
599+
let reth_rocksdb_path = match (reth_rocksdb_path, reth_datadir.clone()) {
600600
(Some(reth_rocksdb_path), _) => PathBuf::from(reth_rocksdb_path),
601601
(None, Some(reth_datadir)) => reth_datadir.join("rocksdb"),
602602
(None, None) => {
603603
eyre::bail!("Either reth_rocksdb_path or reth_datadir must be provided")
604604
}
605605
};
606-
606+
let a = reth_datadir.unwrap_or("NADA".into());
607+
tracing::info!(?reth_rocksdb_path, ?a, "Using RockDB path");
607608
let provider_factory_reopener = ProviderFactoryReopener::new(
608609
db,
609610
chain_spec,

0 commit comments

Comments
 (0)