diff options
author | bnc <bnc@chromium.org> | 2016-01-29 07:22:26 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-01-29 15:23:28 +0000 |
commit | f33fb31b6173ffc6b6a237ae595c549deb03aa58 (patch) | |
tree | 3562f1ee9bf6e0e6f21e0aace528ad2eb01e7b36 /ios/chrome/browser/ios_chrome_io_thread.h | |
parent | 0c7ea64a8b460a71fecc7cd0bc7d04d8dea7a843 (diff) | |
download | chromium_src-f33fb31b6173ffc6b6a237ae595c549deb03aa58.zip chromium_src-f33fb31b6173ffc6b6a237ae595c549deb03aa58.tar.gz chromium_src-f33fb31b6173ffc6b6a237ae595c549deb03aa58.tar.bz2 |
Add Alternative Service field trial.
Before this CL:
* If "use_alternative_service" QUIC trial param was set, both same host and
different host Alt-Svc headers were parsed and used. If this param was not
set, no Alt-Svc headers were parsed, and in-memory entries (from
Alternate-protocol headers or loaded from disk) were only used if they
referred to the same host.
After this CL:
* AltSvc field trial controls whether Alt-Svc headers are parsed.
* "enable_alternative_service_with_different_host" QUIC trial param control
whether in-memory Alt-Svc entries with different host (parsed in current
session or loaded from disk) are used.
Default values are not changed by this CL.
This CL allows testing of same-host Alt-Svc header behavior. If no issues are
encountered, parsing Alt-Svc headers and using same-host entries can be enabled
by default, and Alternate-Protocols removed.
BUG=581331
Review URL: https://codereview.chromium.org/1639913002
Cr-Commit-Position: refs/heads/master@{#372348}
Diffstat (limited to 'ios/chrome/browser/ios_chrome_io_thread.h')
-rw-r--r-- | ios/chrome/browser/ios_chrome_io_thread.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/ios/chrome/browser/ios_chrome_io_thread.h b/ios/chrome/browser/ios_chrome_io_thread.h index 432e9f4..5f0956f 100644 --- a/ios/chrome/browser/ios_chrome_io_thread.h +++ b/ios/chrome/browser/ios_chrome_io_thread.h @@ -140,7 +140,8 @@ class IOSChromeIOThread : public web::WebThreadDelegate { Optional<bool> enable_spdy_ping_based_connection_checking; net::NextProtoVector next_protos; std::set<net::HostPortPair> forced_spdy_exclusions; - Optional<bool> use_alternative_services; + Optional<bool> parse_alternative_services; + Optional<bool> enable_alternative_service_with_different_host; Optional<double> alternative_service_probability_threshold; Optional<bool> enable_npn; @@ -230,6 +231,11 @@ class IOSChromeIOThread : public web::WebThreadDelegate { const VariationParameters& quic_trial_params, Globals* globals); + // Configures Alternative Services in |globals| based on the field trial + // group. + static void ConfigureAltSvcGlobals(base::StringPiece altsvc_trial_group, + IOSChromeIOThread::Globals* globals); + // Configures NPN in |globals| based on the field trial group. static void ConfigureNPNGlobals(base::StringPiece npn_trial_group, Globals* globals); @@ -299,8 +305,8 @@ class IOSChromeIOThread : public web::WebThreadDelegate { // Returns true if QUIC should prefer AES-GCN even without hardware support. static bool ShouldQuicPreferAes(const VariationParameters& quic_trial_params); - // Returns true if QUIC should enable alternative services. - static bool ShouldQuicEnableAlternativeServices( + // Returns true if QUIC should enable alternative services for different host. + static bool ShouldQuicEnableAlternativeServicesForDifferentHost( const VariationParameters& quic_trial_params); // Returns the maximum number of QUIC connections with high packet loss in a |