From 5caf590c06b5f6a0d08dc1dcb3660a4dc2b3fa3b Mon Sep 17 00:00:00 2001 From: Sean McArthur Date: Fri, 12 May 2017 15:39:34 -0700 Subject: [PATCH] perf(http): increase size of initial buffer to 8kb --- src/http/io.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/http/io.rs b/src/http/io.rs index 5c133f06..337c60dc 100644 --- a/src/http/io.rs +++ b/src/http/io.rs @@ -8,7 +8,7 @@ use tokio_io::{AsyncRead, AsyncWrite}; use http::{Http1Transaction, h1, MessageHead, ParseResult, DebugTruncate}; use bytes::{BytesMut, Bytes}; -const INIT_BUFFER_SIZE: usize = 4096; +const INIT_BUFFER_SIZE: usize = 8192; pub const MAX_BUFFER_SIZE: usize = 8192 + 4096 * 100; pub struct Buffered {