From e77e54fe6f7aeba6e52e7ba48f763e7137e15c64 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 5 Nov 2026 21:14:37 +0100 Subject: tor links in order --- src/simtest/bench.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/simtest/bench.rs') diff --git a/src/simtest/bench.rs b/src/simtest/bench.rs index 4d34e4b..08aa365 100644 --- a/src/simtest/bench.rs +++ b/src/simtest/bench.rs @@ -135,6 +135,7 @@ fn mycelium_like(sim: &Sim, ids: &[String]) { /// (Tor carries streams reliably). The simulated net can't make one link slow for a /// while only, so the circuits that are slow at times are slow throughout here. With a /// first wait for answers of 5 s, as Tor's transport waits longer (30 s in production). +/// In order, as a circuit carries a stream: a message never overtakes an earlier one. fn tor_like(sim: &Sim, ids: &[String]) { let mut rng = crate::testrand::Rng::new(9); for (i, from) in ids.iter().enumerate() { @@ -147,6 +148,7 @@ fn tor_like(sim: &Sim, ids: &[String]) { let half = Duration::from_secs_f64(rtt_ms / 2.0 / 1000.0); let link = LinkParams { delay: (half * 4 / 5, half * 6 / 5), + in_order: true, ..LinkParams::default() }; sim.net.set_link(from, to, link.clone()); -- cgit v1.3.1