From f75f455bf0e47be9938ec6efb8038acb1badb869 Mon Sep 17 00:00:00 2001 From: Stefan Lankes Date: Sun, 29 Sep 2024 08:32:52 +0200 Subject: [PATCH] disable nagle algorithm to avoid side effects --- examples/axum/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/axum/src/main.rs b/examples/axum/src/main.rs index 56932d1ed..2a7f22fc7 100644 --- a/examples/axum/src/main.rs +++ b/examples/axum/src/main.rs @@ -9,7 +9,7 @@ async fn main() -> io::Result<()> { let app = Router::new().route("/", get(root)); let listener = net::TcpListener::bind("0.0.0.0:9975").await?; - axum::serve(listener, app).await?; + axum::serve(listener, app).tcp_nodelay(true).await?; Ok(()) }