From 2abc29628937dc3fa6f918e9ef892205c3b6fa77 Mon Sep 17 00:00:00 2001 From: Thomas Heartman Date: Thu, 5 Dec 2024 12:07:41 +0100 Subject: [PATCH] streaming-spike: remove redundant ping --- server/src/http/broadcaster.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/server/src/http/broadcaster.rs b/server/src/http/broadcaster.rs index 12989d0a..46d7efeb 100644 --- a/server/src/http/broadcaster.rs +++ b/server/src/http/broadcaster.rs @@ -83,7 +83,10 @@ impl Broadcaster { self.inner.lock().clients.push(tx); - Sse::from_infallible_receiver(rx).with_keep_alive(Duration::from_secs(30)) + Sse::from_infallible_receiver(rx) + // we're already using remove_stale_clients to clean up disconnected + // clients and send heartbeats. we probably don't need this. + // .with_keep_alive(Duration::from_secs(30)) } /// re-~roadcasts `data` to all clients.