You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by bc...@apache.org on 2015/08/25 22:21:13 UTC

[2/2] trafficserver git commit: TS-3752: Problem with larger headers and HTTP/2 Added back in the debug messages

TS-3752: Problem with larger headers and HTTP/2
Added back in the debug messages

(cherry picked from commit a5818b350d48ea14598d1c876124b393a936f3c9)


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/a248e11c
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/a248e11c
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/a248e11c

Branch: refs/heads/6.0.x
Commit: a248e11c054503dc8ce6d35e6eac7cca7d3e95f2
Parents: 8013e76
Author: Bryan Call <bc...@apache.org>
Authored: Thu Aug 13 14:05:22 2015 -0700
Committer: Bryan Call <bc...@apache.org>
Committed: Tue Aug 25 13:20:46 2015 -0700

----------------------------------------------------------------------
 proxy/http2/Http2ConnectionState.cc | 16 ++++++++++++++--
 1 file changed, 14 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/a248e11c/proxy/http2/Http2ConnectionState.cc
----------------------------------------------------------------------
diff --git a/proxy/http2/Http2ConnectionState.cc b/proxy/http2/Http2ConnectionState.cc
index 7569ff3..4e34a8f 100644
--- a/proxy/http2/Http2ConnectionState.cc
+++ b/proxy/http2/Http2ConnectionState.cc
@@ -861,6 +861,8 @@ Http2ConnectionState::cleanup_streams()
 void
 Http2ConnectionState::set_continued_headers(const char *buf, uint32_t len, Http2StreamId id)
 {
+  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send CONTINUATION frame.", this->ua_session->connection_id());
+
   if (buf && len > 0) {
     if (!continued_buffer.iov_base) {
       continued_buffer.iov_base = static_cast<uint8_t *>(ats_malloc(len));
@@ -906,11 +908,11 @@ Http2ConnectionState::update_initial_rwnd(Http2WindowSize new_size)
 void
 Http2ConnectionState::send_data_frame(FetchSM *fetch_sm)
 {
+  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send DATA frame", this->ua_session->connection_id());
+
   size_t buf_len = BUFFER_SIZE_FOR_INDEX(buffer_size_index[HTTP2_FRAME_TYPE_DATA]) - HTTP2_FRAME_HEADER_LEN;
   uint8_t payload_buffer[buf_len];
 
-  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send DATA frame.", this->ua_session->connection_id());
-
   Http2Stream *stream = static_cast<Http2Stream *>(fetch_sm->ext_get_user_data());
 
   for (;;) {
@@ -971,6 +973,8 @@ Http2ConnectionState::send_data_frame(FetchSM *fetch_sm)
 void
 Http2ConnectionState::send_headers_frame(FetchSM *fetch_sm)
 {
+  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send HEADERS frame.", this->ua_session->connection_id());
+
   const size_t buf_len = BUFFER_SIZE_FOR_INDEX(buffer_size_index[HTTP2_FRAME_TYPE_HEADERS]) - HTTP2_FRAME_HEADER_LEN;
   uint8_t payload_buffer[buf_len];
   size_t payload_length = 0;
@@ -1021,6 +1025,8 @@ Http2ConnectionState::send_headers_frame(FetchSM *fetch_sm)
 void
 Http2ConnectionState::send_rst_stream_frame(Http2StreamId id, Http2ErrorCode ec)
 {
+  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send RST_STREAM frame.", this->ua_session->connection_id());
+
   Http2Frame rst_stream(HTTP2_FRAME_TYPE_RST_STREAM, id, 0);
 
   rst_stream.alloc(buffer_size_index[HTTP2_FRAME_TYPE_RST_STREAM]);
@@ -1070,6 +1076,8 @@ Http2ConnectionState::send_settings_frame(const Http2ConnectionSettings &new_set
 void
 Http2ConnectionState::send_ping_frame(Http2StreamId id, uint8_t flag, const uint8_t *opaque_data)
 {
+  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send PING frame.", this->ua_session->connection_id());
+
   Http2Frame ping(HTTP2_FRAME_TYPE_PING, id, flag);
 
   ping.alloc(buffer_size_index[HTTP2_FRAME_TYPE_PING]);
@@ -1084,6 +1092,8 @@ Http2ConnectionState::send_ping_frame(Http2StreamId id, uint8_t flag, const uint
 void
 Http2ConnectionState::send_goaway_frame(Http2StreamId id, Http2ErrorCode ec)
 {
+  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send GOAWAY frame.", this->ua_session->connection_id());
+
   Http2Frame frame(HTTP2_FRAME_TYPE_GOAWAY, 0, 0);
   Http2Goaway goaway;
 
@@ -1106,6 +1116,8 @@ Http2ConnectionState::send_goaway_frame(Http2StreamId id, Http2ErrorCode ec)
 void
 Http2ConnectionState::send_window_update_frame(Http2StreamId id, uint32_t size)
 {
+  DebugSsn(this->ua_session, "http2_cs", "[%" PRId64 "] Send WINDOW_UPDATE frame.", this->ua_session->connection_id());
+
   // Create WINDOW_UPDATE frame
   Http2Frame window_update(HTTP2_FRAME_TYPE_WINDOW_UPDATE, id, 0x0);
   window_update.alloc(buffer_size_index[HTTP2_FRAME_TYPE_WINDOW_UPDATE]);