OLD | NEW |
---|---|
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 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ | 5 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ |
6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ | 6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ |
7 | 7 |
8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
11 #include "net/base/completion_callback.h" | 11 #include "net/base/completion_callback.h" |
12 #include "net/base/request_priority.h" | 12 #include "net/base/request_priority.h" |
13 #include "net/http/http_auth.h" | 13 #include "net/http/http_auth.h" |
14 #include "net/http/http_auth_controller.h" | 14 #include "net/http/http_auth_controller.h" |
15 #include "net/http/http_request_info.h" | 15 #include "net/http/http_request_info.h" |
16 #include "net/http/http_stream_factory_impl.h" | 16 #include "net/http/http_stream_factory_impl.h" |
17 #include "net/log/net_log.h" | 17 #include "net/log/net_log.h" |
18 #include "net/proxy/proxy_service.h" | 18 #include "net/proxy/proxy_service.h" |
19 #include "net/quic/quic_stream_factory.h" | 19 #include "net/quic/quic_stream_factory.h" |
20 #include "net/socket/client_socket_handle.h" | 20 #include "net/socket/client_socket_handle.h" |
21 #include "net/socket/client_socket_pool_manager.h" | |
21 #include "net/socket/ssl_client_socket.h" | 22 #include "net/socket/ssl_client_socket.h" |
22 #include "net/spdy/spdy_session_key.h" | 23 #include "net/spdy/spdy_session_key.h" |
23 #include "net/ssl/ssl_config_service.h" | 24 #include "net/ssl/ssl_config_service.h" |
24 | 25 |
25 namespace net { | 26 namespace net { |
26 | 27 |
27 class ClientSocketHandle; | 28 class ClientSocketHandle; |
28 class HttpAuthController; | 29 class HttpAuthController; |
29 class HttpNetworkSession; | 30 class HttpNetworkSession; |
30 class HttpStream; | 31 class HttpStream; |
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
228 bool ShouldForceSpdySSL() const; | 229 bool ShouldForceSpdySSL() const; |
229 | 230 |
230 // Should we force SPDY to run without SSL for this stream request. | 231 // Should we force SPDY to run without SSL for this stream request. |
231 bool ShouldForceSpdyWithoutSSL() const; | 232 bool ShouldForceSpdyWithoutSSL() const; |
232 | 233 |
233 // Should we force QUIC for this stream request. | 234 // Should we force QUIC for this stream request. |
234 bool ShouldForceQuic() const; | 235 bool ShouldForceQuic() const; |
235 | 236 |
236 void MaybeMarkAlternativeServiceBroken(); | 237 void MaybeMarkAlternativeServiceBroken(); |
237 | 238 |
239 ClientSocketPoolManager::SocketGroupType GetSocketGroup(); | |
mmenke
2015/04/07 20:27:32
nit: const
Ryan Hamilton
2015/04/08 03:44:45
Done.
| |
240 | |
238 // Record histograms of latency until Connect() completes. | 241 // Record histograms of latency until Connect() completes. |
239 static void LogHttpConnectedMetrics(const ClientSocketHandle& handle); | 242 static void LogHttpConnectedMetrics(const ClientSocketHandle& handle); |
240 | 243 |
241 // Invoked by the transport socket pool after host resolution is complete | 244 // Invoked by the transport socket pool after host resolution is complete |
242 // to allow the connection to be aborted, if a matching SPDY session can | 245 // to allow the connection to be aborted, if a matching SPDY session can |
243 // be found. Will return ERR_SPDY_SESSION_ALREADY_EXISTS if such a | 246 // be found. Will return ERR_SPDY_SESSION_ALREADY_EXISTS if such a |
244 // session is found, and OK otherwise. | 247 // session is found, and OK otherwise. |
245 static int OnHostResolution(SpdySessionPool* spdy_session_pool, | 248 static int OnHostResolution(SpdySessionPool* spdy_session_pool, |
246 const SpdySessionKey& spdy_session_key, | 249 const SpdySessionKey& spdy_session_key, |
247 const AddressList& addresses, | 250 const AddressList& addresses, |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
345 JobStatus other_job_status_; | 348 JobStatus other_job_status_; |
346 | 349 |
347 base::WeakPtrFactory<Job> ptr_factory_; | 350 base::WeakPtrFactory<Job> ptr_factory_; |
348 | 351 |
349 DISALLOW_COPY_AND_ASSIGN(Job); | 352 DISALLOW_COPY_AND_ASSIGN(Job); |
350 }; | 353 }; |
351 | 354 |
352 } // namespace net | 355 } // namespace net |
353 | 356 |
354 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ | 357 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ |
OLD | NEW |