Skip to content

Commit

Permalink
chore: disabled get_batch consensus RPC (#2511)
Browse files Browse the repository at this point in the history
get_batch is not fully implemented yet (neither in era-consensus nor
zksync-era) but it already is consuming resources (db queries and
bandwidth). We should finish implementation and loadtest it before
enabling it again.
  • Loading branch information
pompon0 authored Jul 29, 2024
1 parent 3729468 commit a12699a
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion core/node/consensus/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::collections::HashMap;

use anyhow::Context as _;
use secrecy::{ExposeSecret as _, Secret};
use zksync_concurrency::net;
use zksync_concurrency::{limiter, net, time};
use zksync_config::{
configs,
configs::consensus::{ConsensusConfig, ConsensusSecrets, Host, NodePublicKey},
Expand Down Expand Up @@ -121,6 +121,11 @@ pub(super) fn executor(

let mut rpc = executor::RpcConfig::default();
rpc.get_block_rate = cfg.rpc().get_block_rate();
// Disable batch syncing, because it is not implemented.
rpc.get_batch_rate = limiter::Rate {
burst: 0,
refresh: time::Duration::ZERO,
};

Ok(executor::Config {
server_addr: cfg.server_addr,
Expand Down

0 comments on commit a12699a

Please sign in to comment.