From 81abf901c27837781137a204684b59787d403eeb Mon Sep 17 00:00:00 2001 From: Bryan Stitt Date: Thu, 12 May 2022 19:58:26 +0000 Subject: [PATCH] upgrades --- Dockerfile | 7 +++++-- config/example.toml | 11 ++++++++--- web3-proxy/src/connection.rs | 2 +- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index f2a6be12..860ad7ea 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM rust:1-buster as builder +FROM rust:1-bullseye as builder WORKDIR /usr/src/web3-proxy COPY . . @@ -6,7 +6,10 @@ RUN --mount=type=cache,target=/usr/local/cargo/registry \ --mount=type=cache,target=/usr/src/web3-proxy/target \ cargo install --locked --path ./web3-proxy -FROM debian:buster-slim +FROM debian:bullseye-slim COPY --from=builder /usr/local/cargo/bin/web3-proxy /usr/local/bin/web3-proxy ENTRYPOINT ["web3-proxy"] + +# TODO: lower log level when done with prototyping +ENV RUST_LOG "web3_proxy=debug" diff --git a/config/example.toml b/config/example.toml index 9dd84e92..0792c927 100644 --- a/config/example.toml +++ b/config/example.toml @@ -5,13 +5,18 @@ chain_id = 1 [balanced_rpc_tiers.0] + [balanced_rpc_tiers.0.erigon_archive] + url = "ws://127.0.0.1:8549" + # TODO: double check soft_limit on erigon + soft_limit = 100_000 + [balanced_rpc_tiers.0.geth] url = "ws://127.0.0.1:8546" soft_limit = 200_000 - #[balanced_rpc_tiers.0.ankr] - #url = "https://rpc.ankr.com/eth" - #soft_limit = 3_000 + [balanced_rpc_tiers.0.ankr] + url = "https://rpc.ankr.com/eth" + soft_limit = 3_000 [private_rpcs] diff --git a/web3-proxy/src/connection.rs b/web3-proxy/src/connection.rs index 4c1e7460..845c030f 100644 --- a/web3-proxy/src/connection.rs +++ b/web3-proxy/src/connection.rs @@ -302,7 +302,7 @@ pub struct ActiveRequestHandle(Arc); impl ActiveRequestHandle { fn new(connection: Arc) -> Self { - // TODO: attach the incoming id to this? will be helpful for logging + // TODO: attach a unique id to this // TODO: what ordering?! connection .active_requests