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

Side by Side Diff: net/http/http_network_session.cc

Issue 903213003: Enable QUIC for proxies based on Finch config and command line switch. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed all comments. Added new field in IOThread globals Created 5 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/http/http_network_session.h" 5 #include "net/http/http_network_session.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/debug/stack_trace.h" 10 #include "base/debug/stack_trace.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 spdy_default_protocol(kProtoUnknown), 83 spdy_default_protocol(kProtoUnknown),
84 spdy_stream_initial_recv_window_size(0), 84 spdy_stream_initial_recv_window_size(0),
85 spdy_initial_max_concurrent_streams(0), 85 spdy_initial_max_concurrent_streams(0),
86 spdy_max_concurrent_streams_limit(0), 86 spdy_max_concurrent_streams_limit(0),
87 time_func(&base::TimeTicks::Now), 87 time_func(&base::TimeTicks::Now),
88 force_spdy_over_ssl(true), 88 force_spdy_over_ssl(true),
89 force_spdy_always(false), 89 force_spdy_always(false),
90 use_alternate_protocols(false), 90 use_alternate_protocols(false),
91 alternate_protocol_probability_threshold(1), 91 alternate_protocol_probability_threshold(1),
92 enable_quic(false), 92 enable_quic(false),
93 enable_quic_for_proxies(false),
94 enable_quic_for_data_reduction_proxy(false),
93 enable_quic_port_selection(true), 95 enable_quic_port_selection(true),
94 quic_always_require_handshake_confirmation(false), 96 quic_always_require_handshake_confirmation(false),
95 quic_disable_connection_pooling(false), 97 quic_disable_connection_pooling(false),
96 quic_load_server_info_timeout_ms(0), 98 quic_load_server_info_timeout_ms(0),
97 quic_load_server_info_timeout_srtt_multiplier(0.0f), 99 quic_load_server_info_timeout_srtt_multiplier(0.0f),
98 quic_enable_truncated_connection_ids(false), 100 quic_enable_truncated_connection_ids(false),
99 quic_enable_connection_racing(false), 101 quic_enable_connection_racing(false),
100 quic_clock(NULL), 102 quic_clock(NULL),
101 quic_random(NULL), 103 quic_random(NULL),
102 quic_max_packet_length(kDefaultMaxPacketSize), 104 quic_max_packet_length(kDefaultMaxPacketSize),
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 } 260 }
259 261
260 base::Value* HttpNetworkSession::SpdySessionPoolInfoToValue() const { 262 base::Value* HttpNetworkSession::SpdySessionPoolInfoToValue() const {
261 return spdy_session_pool_.SpdySessionPoolInfoToValue(); 263 return spdy_session_pool_.SpdySessionPoolInfoToValue();
262 } 264 }
263 265
264 base::Value* HttpNetworkSession::QuicInfoToValue() const { 266 base::Value* HttpNetworkSession::QuicInfoToValue() const {
265 base::DictionaryValue* dict = new base::DictionaryValue(); 267 base::DictionaryValue* dict = new base::DictionaryValue();
266 dict->Set("sessions", quic_stream_factory_.QuicStreamFactoryInfoToValue()); 268 dict->Set("sessions", quic_stream_factory_.QuicStreamFactoryInfoToValue());
267 dict->SetBoolean("quic_enabled", params_.enable_quic); 269 dict->SetBoolean("quic_enabled", params_.enable_quic);
270 dict->SetBoolean("quic_enabled_for_proxies", params_.enable_quic_for_proxies);
271 dict->SetBoolean("quic_enabled_for_data_reduction_proxy",
272 params_.enable_quic_for_data_reduction_proxy);
268 dict->SetBoolean("enable_quic_port_selection", 273 dict->SetBoolean("enable_quic_port_selection",
269 params_.enable_quic_port_selection); 274 params_.enable_quic_port_selection);
270 base::ListValue* connection_options = new base::ListValue; 275 base::ListValue* connection_options = new base::ListValue;
271 for (QuicTagVector::const_iterator it = 276 for (QuicTagVector::const_iterator it =
272 params_.quic_connection_options.begin(); 277 params_.quic_connection_options.begin();
273 it != params_.quic_connection_options.end(); ++it) { 278 it != params_.quic_connection_options.end(); ++it) {
274 connection_options->AppendString("'" + QuicUtils::TagToString(*it) + "'"); 279 connection_options->AppendString("'" + QuicUtils::TagToString(*it) + "'");
275 } 280 }
276 dict->Set("connection_options", connection_options); 281 dict->Set("connection_options", connection_options);
277 dict->SetString("origin_to_force_quic_on", 282 dict->SetString("origin_to_force_quic_on",
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 case WEBSOCKET_SOCKET_POOL: 327 case WEBSOCKET_SOCKET_POOL:
323 return websocket_socket_pool_manager_.get(); 328 return websocket_socket_pool_manager_.get();
324 default: 329 default:
325 NOTREACHED(); 330 NOTREACHED();
326 break; 331 break;
327 } 332 }
328 return NULL; 333 return NULL;
329 } 334 }
330 335
331 } // namespace net 336 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698