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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.h

Issue 2442633002: Add a QUIC proxy server to the list of QUIC servers supported at start up (Closed)
Patch Set: Rebased, Addressed ryansturm comments Created 4 years, 2 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: components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.h
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.h b/components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.h
index 7d8b1b55e4cee3d456978e1395ee1d312b6cf845..16fa3affca6d68eed67a1e63563aa698600bcded 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.h
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.h
@@ -10,6 +10,7 @@
#include "base/macros.h"
#include "net/base/proxy_delegate.h"
#include "net/proxy/proxy_retry_info.h"
+#include "net/proxy/proxy_server.h"
#include "url/gurl.h"
namespace net {
@@ -19,7 +20,6 @@ class HttpResponseHeaders;
class NetLog;
class ProxyConfig;
class ProxyInfo;
-class ProxyServer;
class ProxyService;
class URLRequest;
}
@@ -71,6 +71,7 @@ class DataReductionProxyDelegate : public net::ProxyDelegate {
net::ProxyServer* alternative_proxy_server) const override;
void OnAlternativeProxyBroken(
const net::ProxyServer& alternative_proxy_server) override;
+ net::ProxyServer GetQuicSupportedProxyServerAtStartUp() const override;
// Protected so that it can be overridden during testing.
// Returns true if |proxy_server| supports QUIC.
@@ -85,10 +86,23 @@ class DataReductionProxyDelegate : public net::ProxyDelegate {
QUIC_PROXY_STATUS_BOUNDARY
};
+ // Availability status of data reduction proxy that supports 0-RTT QUIC at
+ // startup. Protected so that the enum values are accessible for testing.
+ enum QuicProxyAtStartup {
+ QUIC_PROXY_AT_STARTUP_AVAILABLE,
+ QUIC_PROXY_AT_STARTUP_BROKEN,
+ QUIC_PROXY_AT_STARTUP_UNAVAILABLE,
+ QUIC_PROXY_AT_STARTUP_BOUNDARY,
+ };
+
private:
// Records the availability status of data reduction proxy.
void RecordQuicProxyStatus(QuicProxyStatus status) const;
+ // Records the availability status of data reduction proxy that support 0-RTT
+ // QUIC at startup.
+ void RecordQuicProxyAtStartupStatus(QuicProxyAtStartup status) const;
+
const DataReductionProxyConfig* config_;
const DataReductionProxyConfigurator* configurator_;
DataReductionProxyEventCreator* event_creator_;

Powered by Google App Engine
This is Rietveld 408576698