diff options
author | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-10 07:32:53 +0000 |
---|---|---|
committer | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-10 07:32:53 +0000 |
commit | 17291a02bb3589d94ceb63fbb14ca59fff75e163 (patch) | |
tree | dff2d5c6919d567ced7dcbfeea6c8daa580b0673 /net/spdy | |
parent | cd6e0ba8e0d9435222349ff4d4d7b19d137d9c57 (diff) | |
download | chromium_src-17291a02bb3589d94ceb63fbb14ca59fff75e163.zip chromium_src-17291a02bb3589d94ceb63fbb14ca59fff75e163.tar.gz chromium_src-17291a02bb3589d94ceb63fbb14ca59fff75e163.tar.bz2 |
Migrate HttpAlternateProtocols to HttpServerPropertiesImpl.
Hooks in HttpServerPropertiesManager also. No persistence done yet. This is all plumbing.
Also require HttpServerProperties in HttpNetworkSession::Params.
BUG=98472
TEST=none
Review URL: http://codereview.chromium.org/8211003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@104696 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/spdy')
-rw-r--r-- | net/spdy/spdy_network_transaction_unittest.cc | 4 | ||||
-rw-r--r-- | net/spdy/spdy_test_util.cc | 4 | ||||
-rw-r--r-- | net/spdy/spdy_test_util.h | 2 |
3 files changed, 8 insertions, 2 deletions
diff --git a/net/spdy/spdy_network_transaction_unittest.cc b/net/spdy/spdy_network_transaction_unittest.cc index 4a9e111..32b5b7c 100644 --- a/net/spdy/spdy_network_transaction_unittest.cc +++ b/net/spdy/spdy_network_transaction_unittest.cc @@ -124,9 +124,9 @@ class SpdyNetworkTransactionTest HttpStreamFactory::set_force_spdy_always(false); switch (test_type_) { case SPDYNPN: - session_->mutable_alternate_protocols()->SetAlternateProtocolFor( + session_->http_server_properties()->SetAlternateProtocol( HostPortPair("www.google.com", 80), 443, - HttpAlternateProtocols::NPN_SPDY_2); + NPN_SPDY_2); HttpStreamFactory::set_use_alternate_protocols(true); HttpStreamFactory::set_next_protos(kExpectedNPNString); break; diff --git a/net/spdy/spdy_test_util.cc b/net/spdy/spdy_test_util.cc index efe1efa..ec0f5d7 100644 --- a/net/spdy/spdy_test_util.cc +++ b/net/spdy/spdy_test_util.cc @@ -12,6 +12,7 @@ #include "base/string_util.h" #include "net/http/http_network_session.h" #include "net/http/http_network_transaction.h" +#include "net/http/http_server_properties_impl.h" #include "net/spdy/spdy_framer.h" #include "net/spdy/spdy_http_utils.h" @@ -923,6 +924,7 @@ HttpNetworkSession* SpdySessionDependencies::SpdyCreateSession( params.ssl_config_service = session_deps->ssl_config_service; params.http_auth_handler_factory = session_deps->http_auth_handler_factory.get(); + params.http_server_properties = &session_deps->http_server_properties; return new HttpNetworkSession(params); } @@ -938,6 +940,7 @@ HttpNetworkSession* SpdySessionDependencies::SpdyCreateSessionDeterministic( params.ssl_config_service = session_deps->ssl_config_service; params.http_auth_handler_factory = session_deps->http_auth_handler_factory.get(); + params.http_server_properties = &session_deps->http_server_properties; return new HttpNetworkSession(params); } @@ -949,6 +952,7 @@ SpdyURLRequestContext::SpdyURLRequestContext() storage_.set_ssl_config_service(new SSLConfigServiceDefaults); storage_.set_http_auth_handler_factory(HttpAuthHandlerFactory::CreateDefault( host_resolver())); + storage_.set_http_server_properties(new HttpServerPropertiesImpl); net::HttpNetworkSession::Params params; params.client_socket_factory = &socket_factory_; params.host_resolver = host_resolver(); diff --git a/net/spdy/spdy_test_util.h b/net/spdy/spdy_test_util.h index 1ccdb37..2d724bd 100644 --- a/net/spdy/spdy_test_util.h +++ b/net/spdy/spdy_test_util.h @@ -17,6 +17,7 @@ #include "net/http/http_cache.h" #include "net/http/http_network_session.h" #include "net/http/http_network_layer.h" +#include "net/http/http_server_properties_impl.h" #include "net/http/http_transaction_factory.h" #include "net/proxy/proxy_service.h" #include "net/socket/socket_test_util.h" @@ -355,6 +356,7 @@ class SpdySessionDependencies { scoped_ptr<MockClientSocketFactory> socket_factory; scoped_ptr<DeterministicMockClientSocketFactory> deterministic_socket_factory; scoped_ptr<HttpAuthHandlerFactory> http_auth_handler_factory; + HttpServerPropertiesImpl http_server_properties; }; class SpdyURLRequestContext : public URLRequestContext { |