summaryrefslogtreecommitdiff
path: root/chromium/net/quic/core/quic_spdy_session.h
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/net/quic/core/quic_spdy_session.h')
-rw-r--r--chromium/net/quic/core/quic_spdy_session.h32
1 files changed, 16 insertions, 16 deletions
diff --git a/chromium/net/quic/core/quic_spdy_session.h b/chromium/net/quic/core/quic_spdy_session.h
index 17115a76139..1855d4a99c9 100644
--- a/chromium/net/quic/core/quic_spdy_session.h
+++ b/chromium/net/quic/core/quic_spdy_session.h
@@ -15,6 +15,7 @@
#include "net/quic/core/quic_spdy_stream.h"
#include "net/quic/platform/api/quic_export.h"
#include "net/quic/platform/api/quic_string_piece.h"
+#include "net/spdy/core/http2_frame_decoder_adapter.h"
namespace net {
@@ -76,7 +77,7 @@ class QUIC_EXPORT_PRIVATE QuicSpdySession : public QuicSession {
size_t frame_len,
const QuicHeaderList& header_list);
- // Sends contents of |iov| to spdy_framer_, returns number of bytes processd.
+ // Sends contents of |iov| to h2_deframer_, returns number of bytes processed.
size_t ProcessHeaderData(const struct iovec& iov, QuicTime timestamp);
// Writes |headers| for the stream |id| to the dedicated headers stream.
@@ -148,24 +149,26 @@ class QUIC_EXPORT_PRIVATE QuicSpdySession : public QuicSession {
// aggressively.
virtual bool ShouldReleaseHeadersStreamSequencerBuffer();
- SpdyFramer* spdy_framer() { return &spdy_framer_; }
-
void CloseConnectionWithDetails(QuicErrorCode error,
const std::string& details);
// Sets how much encoded data the hpack decoder of spdy_framer_ is willing to
// buffer.
void set_max_decode_buffer_size_bytes(size_t max_decode_buffer_size_bytes) {
- spdy_framer_.set_max_decode_buffer_size_bytes(max_decode_buffer_size_bytes);
+ h2_deframer_.GetHpackDecoder()->set_max_decode_buffer_size_bytes(
+ max_decode_buffer_size_bytes);
}
+ // TODO(dahollings): Move to private upon deprecation of
+ // --quic_restart_flag_quic_header_list_size.
void set_max_uncompressed_header_bytes(
size_t set_max_uncompressed_header_bytes);
+ void set_max_inbound_header_list_size(size_t max_inbound_header_list_size) {
+ max_inbound_header_list_size_ = max_inbound_header_list_size;
+ }
+
protected:
- // TODO(ckrasic) - remove these two when
- // FLAGS_quic_reloadable_flag_quic_refactor_stream_creation is
- // deprecated.
// Override CreateIncomingDynamicStream() and CreateOutgoingDynamicStream()
// with QuicSpdyStream return type to make sure that all data streams are
// QuicSpdyStreams.
@@ -173,16 +176,8 @@ class QUIC_EXPORT_PRIVATE QuicSpdySession : public QuicSession {
QuicSpdyStream* CreateOutgoingDynamicStream(SpdyPriority priority) override =
0;
- QuicSpdyStream* MaybeCreateIncomingDynamicStream(QuicStreamId id) override;
- QuicSpdyStream* MaybeCreateOutgoingDynamicStream(
- SpdyPriority priority) override;
-
QuicSpdyStream* GetSpdyDataStream(const QuicStreamId stream_id);
- // TODO(ckrasic) - remove these two when
- // FLAGS_quic_reloadable_flag_quic_refactor_stream_creation is
- // depreacted.
-
// If an incoming stream can be created, return true.
virtual bool ShouldCreateIncomingDynamicStream(QuicStreamId id) = 0;
@@ -205,7 +200,7 @@ class QUIC_EXPORT_PRIVATE QuicSpdySession : public QuicSession {
std::unique_ptr<QuicHpackDebugVisitor> visitor);
// Sets the maximum size of the header compression table spdy_framer_ is
- // willing to use to decode header blocks.
+ // willing to use to encode header blocks.
void UpdateHeaderEncoderTableSize(uint32_t value);
// Called when SETTINGS_ENABLE_PUSH is received, only supported on
@@ -263,6 +258,10 @@ class QUIC_EXPORT_PRIVATE QuicSpdySession : public QuicSession {
std::unique_ptr<QuicHeadersStream> headers_stream_;
+ // The maximum size of a header block that will be accepted from the peer,
+ // defined per spec as key + value + overhead per field (uncompressed).
+ size_t max_inbound_header_list_size_;
+
// If set, redirect all data through the headers stream in order to
// simulate forced HOL blocking between streams as happens in
// HTTP/2 over TCP.
@@ -291,6 +290,7 @@ class QUIC_EXPORT_PRIVATE QuicSpdySession : public QuicSession {
QuicTime prev_max_timestamp_;
SpdyFramer spdy_framer_;
+ Http2DecoderAdapter h2_deframer_;
std::unique_ptr<SpdyFramerVisitor> spdy_framer_visitor_;
DISALLOW_COPY_AND_ASSIGN(QuicSpdySession);