Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(34)

Unified Diff: net/quic/quic_client_session.h

Issue 1208933004: QUIC - disable QUIC under recent pathological connection errors. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/quic/quic_client_session.h
diff --git a/net/quic/quic_client_session.h b/net/quic/quic_client_session.h
index 414b9069b105cbdfdbbf5f2927d9857475d2f1f1..4156f6bda18aed3a9640b01045f88c5267cb4b5d 100644
--- a/net/quic/quic_client_session.h
+++ b/net/quic/quic_client_session.h
@@ -41,6 +41,18 @@ namespace test {
class QuicClientSessionPeer;
} // namespace test
+// Epitaphs will be used to track the most recent departed sessions,
Ryan Hamilton 2015/06/30 18:55:31 Can you define "epitath" in this context?
Buck 2015/07/01 19:06:19 I've dropped epitaph everywhere, and switched to D
+// to enable certain policies for when to disable QUIC, based on K
+// of N type thresholds.
+// Note: these values must be kept in sync with the corresponding values
+// of QuicDisabledReason in: tools/metrics/histograms/histograms.xml
+enum QuicClientSessionEpitaph {
Ryan Hamilton 2015/06/30 18:55:31 nit: might as well nest this enum inside of QuicCl
Buck 2015/07/01 19:06:19 I've moved it (enum QuicDisabledReason) to quic_ty
Ryan Hamilton 2015/07/06 18:25:41 quic_types.h is part of the shared code. Since the
Buck 2015/07/06 21:39:32 Ok, QuicClientSession::DisabledReason it is.
+ QUIC_EPITAPH_RIP = 0,
Ryan Hamilton 2015/06/30 18:55:31 What does "RIP" mean in this context? Perhaps add
Buck 2015/07/01 19:06:19 Corresponding entry in QuicDisabledReason has a co
+ QUIC_EPITAPH_PUBLIC_RESET_POST_HANDSHAKE = 1,
+ QUIC_EPITAPH_TIMEOUT_STREAMS_OPEN = 2,
+ QUIC_EPITAPH_MAX = 3,
Ryan Hamilton 2015/06/30 18:55:31 Could the packet loss code take advantage of this,
Buck 2015/07/01 19:06:19 Somewhat. As per above, I've moved it and also ad
+};
+
class NET_EXPORT_PRIVATE QuicClientSession : public QuicClientSessionBase,
public QuicPacketReader::Visitor {
public:
@@ -194,6 +206,8 @@ class NET_EXPORT_PRIVATE QuicClientSession : public QuicClientSessionBase,
const QuicServerId& server_id() const { return server_id_; }
+ const QuicClientSessionEpitaph epitaph() const { return epitaph_; }
+
protected:
// QuicSession methods:
QuicDataStream* CreateIncomingDynamicStream(QuicStreamId id) override;
@@ -261,6 +275,7 @@ class NET_EXPORT_PRIVATE QuicClientSession : public QuicClientSessionBase,
// True when the session is going away, and streams may no longer be created
// on this session. Existing stream will continue to be processed.
bool going_away_;
+ QuicClientSessionEpitaph epitaph_;
base::WeakPtrFactory<QuicClientSession> weak_factory_;
DISALLOW_COPY_AND_ASSIGN(QuicClientSession);

Powered by Google App Engine
This is Rietveld 408576698