lets modify web3 proxyd manually copy pasta
This commit is contained in:
parent
c7dcc4aac3
commit
5a54fc5e99
9
Cargo.lock
generated
9
Cargo.lock
generated
@ -1991,15 +1991,6 @@ dependencies = [
|
|||||||
"winapi",
|
"winapi",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "fsevent-sys"
|
|
||||||
version = "4.1.0"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "76ee7a02da4d231650c7cea31349b889be2f45ddb3ef3032d2ec8185f6313fd2"
|
|
||||||
dependencies = [
|
|
||||||
"libc",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "fstrings"
|
name = "fstrings"
|
||||||
version = "0.2.3"
|
version = "0.2.3"
|
||||||
|
@ -27,11 +27,7 @@ thread-fast-rng = { path = "../thread-fast-rng" }
|
|||||||
|
|
||||||
anyhow = { version = "1.0.69", features = ["backtrace"] }
|
anyhow = { version = "1.0.69", features = ["backtrace"] }
|
||||||
argh = "0.1.10"
|
argh = "0.1.10"
|
||||||
<<<<<<< HEAD
|
|
||||||
axum = { version = "0.6.8", features = ["headers", "ws"] }
|
axum = { version = "0.6.8", features = ["headers", "ws"] }
|
||||||
=======
|
|
||||||
axum = { version = "0.6.7", features = ["headers", "ws"] }
|
|
||||||
>>>>>>> 698d53d (cargo upgrade)
|
|
||||||
axum-client-ip = "0.4.0"
|
axum-client-ip = "0.4.0"
|
||||||
axum-macros = "0.3.4"
|
axum-macros = "0.3.4"
|
||||||
chrono = "0.4.23"
|
chrono = "0.4.23"
|
||||||
@ -75,11 +71,7 @@ serde = { version = "1.0.152", features = [] }
|
|||||||
serde_json = { version = "1.0.93", default-features = false, features = ["alloc", "raw_value"] }
|
serde_json = { version = "1.0.93", default-features = false, features = ["alloc", "raw_value"] }
|
||||||
serde_prometheus = "0.2.1"
|
serde_prometheus = "0.2.1"
|
||||||
siwe = "0.5.0"
|
siwe = "0.5.0"
|
||||||
<<<<<<< HEAD
|
|
||||||
time = "0.3.20"
|
time = "0.3.20"
|
||||||
=======
|
|
||||||
time = "0.3.19"
|
|
||||||
>>>>>>> 698d53d (cargo upgrade)
|
|
||||||
tokio = { version = "1.25.0", features = ["full"] }
|
tokio = { version = "1.25.0", features = ["full"] }
|
||||||
tokio-stream = { version = "0.1.12", features = ["sync"] }
|
tokio-stream = { version = "0.1.12", features = ["sync"] }
|
||||||
tokio-uring = { version = "0.4.0", optional = true }
|
tokio-uring = { version = "0.4.0", optional = true }
|
||||||
|
@ -10,6 +10,7 @@ use tokio::sync::broadcast;
|
|||||||
use web3_proxy::app::{flatten_handle, flatten_handles, Web3ProxyApp};
|
use web3_proxy::app::{flatten_handle, flatten_handles, Web3ProxyApp};
|
||||||
use web3_proxy::config::TopConfig;
|
use web3_proxy::config::TopConfig;
|
||||||
use web3_proxy::{frontend, prometheus};
|
use web3_proxy::{frontend, prometheus};
|
||||||
|
use anyhow::Context;
|
||||||
|
|
||||||
/// start the main proxy daemon
|
/// start the main proxy daemon
|
||||||
#[derive(FromArgs, PartialEq, Debug, Eq)]
|
#[derive(FromArgs, PartialEq, Debug, Eq)]
|
||||||
@ -113,23 +114,23 @@ async fn run(
|
|||||||
|
|
||||||
// wait until the app has seen its first consensus head block
|
// wait until the app has seen its first consensus head block
|
||||||
// if backups were included, wait a little longer
|
// if backups were included, wait a little longer
|
||||||
for _ in 0..3 {
|
// for _ in 0..3 {
|
||||||
let _ = spawned_app.consensus_connections_watcher.changed().await;
|
// let _ = spawned_app.consensus_connections_watcher.changed().await;
|
||||||
|
//
|
||||||
let consensus = spawned_app
|
// let consensus = spawned_app
|
||||||
.consensus_connections_watcher
|
// .consensus_connections_watcher
|
||||||
.borrow_and_update();
|
// .borrow_and_update();
|
||||||
|
//
|
||||||
if *consensus.context("Channel closed!")?.backups_needed {
|
// if *consensus.context("Channel closed!")?.backups_needed {
|
||||||
info!(
|
// info!(
|
||||||
"waiting longer. found consensus with backups: {}",
|
// "waiting longer. found consensus with backups: {}",
|
||||||
*consensus.context("Channel closed!")?.head_block.as_ref().unwrap(),
|
// *consensus.context("Channel closed!")?.head_block.as_ref().unwrap(),
|
||||||
);
|
// );
|
||||||
} else {
|
// } else {
|
||||||
// TODO: also check that we have at least one archive node connected?
|
// // TODO: also check that we have at least one archive node connected?
|
||||||
break;
|
// break;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
// start the frontend port
|
// start the frontend port
|
||||||
let frontend_handle = tokio::spawn(frontend::serve(
|
let frontend_handle = tokio::spawn(frontend::serve(
|
||||||
|
Loading…
Reference in New Issue
Block a user