Skip to content

Commit 2db5234

Browse files
committed
fix:fix config
Signed-off-by: Chen Kai <[email protected]>
1 parent 8a56398 commit 2db5234

File tree

16 files changed

+160
-141
lines changed

16 files changed

+160
-141
lines changed

Cargo.lock

+17-61
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[workspace]
2-
members = ["bin/archiver", "bin/api", "crates/config", "crates/storage", "crates/beacon"]
2+
members = ["bin/archiver", "bin/api", "crates/storage", "crates/beacon"]
33
default-members = ["bin/archiver", "bin/api"]
44
resolver = "2"
55

bin/api/src/api.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ use warp::{reply, Filter, Rejection, Reply};
99
use warp_utils::query::multi_key_query;
1010

1111
use blob_archiver_beacon::beacon_client::BeaconClient;
12-
use blob_archiver_storage::Storage;
12+
use blob_archiver_storage::storage::Storage;
1313

1414
pub struct Api {
1515
#[allow(dead_code)]
@@ -155,7 +155,7 @@ mod tests {
155155
use blob_archiver_beacon::beacon_client::BeaconClientStub;
156156
use blob_archiver_beacon::blob_test_helper;
157157
use blob_archiver_storage::fs::{FSStorage, TestFSStorage};
158-
use blob_archiver_storage::{BlobData, BlobSidecars, Header, StorageWriter};
158+
use blob_archiver_storage::storage::{BlobData, BlobSidecars, Header, StorageWriter};
159159

160160
use crate::INIT;
161161

bin/archiver/src/api.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ mod tests {
142142
use blob_archiver_beacon::beacon_client::BeaconClientStub;
143143
use blob_archiver_beacon::blob_test_helper;
144144
use blob_archiver_storage::fs::{FSStorage, TestFSStorage};
145-
use blob_archiver_storage::Storage;
145+
use blob_archiver_storage::storage::Storage;
146146

147147
use crate::api::Api;
148148
use crate::archiver::{Archiver, Config};
@@ -164,6 +164,8 @@ mod tests {
164164
poll_interval: Duration::from_secs(5),
165165
listen_addr: "".to_string(),
166166
origin_block: *blob_test_helper::ORIGIN_BLOCK,
167+
beacon_config: Default::default(),
168+
storage_config: Default::default(),
167169
};
168170
let archiver = Archiver::new(beacon_client.clone(), storage, config, shutdown_rx);
169171
(archiver, beacon_client)

bin/archiver/src/archiver.rs

+12-2
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,10 @@ use tokio::sync::Mutex;
1313
use tokio::time::{interval, sleep};
1414
use tracing::log::{debug, error, info, trace};
1515

16+
use blob_archiver_beacon::beacon_client;
1617
use blob_archiver_beacon::beacon_client::BeaconClient;
17-
use blob_archiver_storage::{
18+
use blob_archiver_storage::storage;
19+
use blob_archiver_storage::storage::{
1820
BackfillProcess, BackfillProcesses, BlobData, BlobSidecars, Header, LockFile, Storage,
1921
};
2022
use uuid::Uuid;
@@ -50,6 +52,10 @@ pub struct Config {
5052
pub listen_addr: String,
5153

5254
pub origin_block: Hash256,
55+
56+
pub beacon_config: beacon_client::Config,
57+
58+
pub storage_config: storage::Config,
5359
}
5460

5561
pub struct Archiver {
@@ -470,7 +476,7 @@ mod tests {
470476
use blob_archiver_beacon::blob_test_helper;
471477
use blob_archiver_beacon::blob_test_helper::{new_blob_sidecars, START_SLOT};
472478
use blob_archiver_storage::fs::{FSStorage, TestFSStorage};
473-
use blob_archiver_storage::StorageReader;
479+
use blob_archiver_storage::storage::StorageReader;
474480
use eth2::types::MainnetEthSpec;
475481
use eth2::{BeaconNodeHttpClient, SensitiveUrl, Timeouts};
476482
use tracing_subscriber::layer::SubscriberExt;
@@ -492,6 +498,8 @@ mod tests {
492498
poll_interval: Duration::from_secs(5),
493499
listen_addr: "".to_string(),
494500
origin_block: *blob_test_helper::ORIGIN_BLOCK,
501+
beacon_config: Default::default(),
502+
storage_config: Default::default(),
495503
};
496504
let archiver = Archiver::new(beacon_client.clone(), storage, config, shutdown_rx);
497505
(archiver, beacon_client)
@@ -1815,6 +1823,8 @@ mod tests {
18151823
poll_interval: Duration::from_secs(5),
18161824
listen_addr: "".to_string(),
18171825
origin_block: *blob_test_helper::ORIGIN_BLOCK,
1826+
beacon_config: Default::default(),
1827+
storage_config: Default::default(),
18181828
};
18191829
let archiver = Archiver::new(
18201830
Arc::new(Mutex::new(beacon_client_eth2)),

0 commit comments

Comments
 (0)