From 0d82405a7bf6a812bdfe50885f4684cd9421fc92 Mon Sep 17 00:00:00 2001 From: Sean McArthur Date: Wed, 26 May 2021 12:54:09 -0700 Subject: [PATCH] refactor(http1): emit trace logs when buffering write data --- src/proto/h1/io.rs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/proto/h1/io.rs b/src/proto/h1/io.rs index 48c6d87885..4e6efba680 100644 --- a/src/proto/h1/io.rs +++ b/src/proto/h1/io.rs @@ -512,6 +512,11 @@ where let head = self.headers_mut(); head.maybe_unshift(buf.remaining()); + trace!( + self.len = head.remaining(), + buf.len = buf.remaining(), + "buffer.flatten" + ); //perf: This is a little faster than >::put, //but accomplishes the same result. loop { @@ -527,6 +532,11 @@ where } } WriteStrategy::Queue => { + trace!( + self.len = self.remaining(), + buf.len = buf.remaining(), + "buffer.queue" + ); self.queue.push(buf.into()); } }