From 146ed903a0e0d19656403dff876a1209990947b0 Mon Sep 17 00:00:00 2001 From: Bastian Gruber Date: Tue, 16 Apr 2024 13:11:25 -0300 Subject: [PATCH] fix: increase p2p batch size --- crates/topos-p2p/src/behaviour/gossip.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/topos-p2p/src/behaviour/gossip.rs b/crates/topos-p2p/src/behaviour/gossip.rs index eaf6991ef..ac4545c6d 100644 --- a/crates/topos-p2p/src/behaviour/gossip.rs +++ b/crates/topos-p2p/src/behaviour/gossip.rs @@ -25,7 +25,7 @@ use crate::{constants, event::ComposedEvent, TOPOS_ECHO, TOPOS_GOSSIP, TOPOS_REA use super::HealthStatus; -const MAX_BATCH_SIZE: usize = 10; +const MAX_BATCH_SIZE: usize = 1024; pub struct Behaviour { batch_size: usize, @@ -76,7 +76,7 @@ impl Behaviour { .unwrap_or(Ok(MAX_BATCH_SIZE)) .unwrap(); let gossipsub = gossipsub::ConfigBuilder::default() - .max_transmit_size(2 * 1024 * 1024) + .max_transmit_size(100 * 1024 * 1024) .validation_mode(gossipsub::ValidationMode::Strict) .message_id_fn(|msg_id| { // Content based id