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

Side by Side Diff: net/http/http_stream_factory_impl.h

Issue 10218007: net: don't remember TLS intolerant servers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressing wtc's comments Created 8 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « net/http/http_stream_factory.h ('k') | net/http/http_stream_factory_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_IMPL_H_ 5 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_IMPL_H_
6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_H_ 6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <vector> 10 #include <vector>
(...skipping 24 matching lines...) Expand all
35 const HttpRequestInfo& info, 35 const HttpRequestInfo& info,
36 const SSLConfig& server_ssl_config, 36 const SSLConfig& server_ssl_config,
37 const SSLConfig& proxy_ssl_config, 37 const SSLConfig& proxy_ssl_config,
38 HttpStreamRequest::Delegate* delegate, 38 HttpStreamRequest::Delegate* delegate,
39 const BoundNetLog& net_log) OVERRIDE; 39 const BoundNetLog& net_log) OVERRIDE;
40 40
41 virtual void PreconnectStreams(int num_streams, 41 virtual void PreconnectStreams(int num_streams,
42 const HttpRequestInfo& info, 42 const HttpRequestInfo& info,
43 const SSLConfig& server_ssl_config, 43 const SSLConfig& server_ssl_config,
44 const SSLConfig& proxy_ssl_config) OVERRIDE; 44 const SSLConfig& proxy_ssl_config) OVERRIDE;
45 virtual void AddTLSIntolerantServer(const HostPortPair& server) OVERRIDE;
46 virtual bool IsTLSIntolerantServer(const HostPortPair& server) const OVERRIDE;
47 virtual base::Value* PipelineInfoToValue() const OVERRIDE; 45 virtual base::Value* PipelineInfoToValue() const OVERRIDE;
48 46
49 // HttpPipelinedHostPool::Delegate interface 47 // HttpPipelinedHostPool::Delegate interface
50 virtual void OnHttpPipelinedHostHasAdditionalCapacity( 48 virtual void OnHttpPipelinedHostHasAdditionalCapacity(
51 HttpPipelinedHost* host) OVERRIDE; 49 HttpPipelinedHost* host) OVERRIDE;
52 50
53 private: 51 private:
54 class Request; 52 class Request;
55 class Job; 53 class Job;
56 54
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 // Called when the Preconnect completes. Used for testing. 90 // Called when the Preconnect completes. Used for testing.
93 virtual void OnPreconnectsCompleteInternal() {} 91 virtual void OnPreconnectsCompleteInternal() {}
94 92
95 void AbortPipelinedRequestsWithKey(const Job* job, 93 void AbortPipelinedRequestsWithKey(const Job* job,
96 const HttpPipelinedHost::Key& key, 94 const HttpPipelinedHost::Key& key,
97 int status, 95 int status,
98 const SSLConfig& used_ssl_config); 96 const SSLConfig& used_ssl_config);
99 97
100 HttpNetworkSession* const session_; 98 HttpNetworkSession* const session_;
101 99
102 std::set<HostPortPair> tls_intolerant_servers_;
103
104 // All Requests are handed out to clients. By the time HttpStreamFactoryImpl 100 // All Requests are handed out to clients. By the time HttpStreamFactoryImpl
105 // is destroyed, all Requests should be deleted (which should remove them from 101 // is destroyed, all Requests should be deleted (which should remove them from
106 // |request_map_|. The Requests will delete the corresponding job. 102 // |request_map_|. The Requests will delete the corresponding job.
107 std::map<const Job*, Request*> request_map_; 103 std::map<const Job*, Request*> request_map_;
108 104
109 SpdySessionRequestMap spdy_session_request_map_; 105 SpdySessionRequestMap spdy_session_request_map_;
110 HttpPipeliningRequestMap http_pipelining_request_map_; 106 HttpPipeliningRequestMap http_pipelining_request_map_;
111 107
112 HttpPipelinedHostPool http_pipelined_host_pool_; 108 HttpPipelinedHostPool http_pipelined_host_pool_;
113 109
114 // These jobs correspond to jobs orphaned by Requests and now owned by 110 // These jobs correspond to jobs orphaned by Requests and now owned by
115 // HttpStreamFactoryImpl. Since they are no longer tied to Requests, they will 111 // HttpStreamFactoryImpl. Since they are no longer tied to Requests, they will
116 // not be canceled when Requests are canceled. Therefore, in 112 // not be canceled when Requests are canceled. Therefore, in
117 // ~HttpStreamFactoryImpl, it is possible for some jobs to still exist in this 113 // ~HttpStreamFactoryImpl, it is possible for some jobs to still exist in this
118 // set. Leftover jobs will be deleted when the factory is destroyed. 114 // set. Leftover jobs will be deleted when the factory is destroyed.
119 std::set<const Job*> orphaned_job_set_; 115 std::set<const Job*> orphaned_job_set_;
120 116
121 // These jobs correspond to preconnect requests and have no associated Request 117 // These jobs correspond to preconnect requests and have no associated Request
122 // object. They're owned by HttpStreamFactoryImpl. Leftover jobs will be 118 // object. They're owned by HttpStreamFactoryImpl. Leftover jobs will be
123 // deleted when the factory is destroyed. 119 // deleted when the factory is destroyed.
124 std::set<const Job*> preconnect_job_set_; 120 std::set<const Job*> preconnect_job_set_;
125 121
126 DISALLOW_COPY_AND_ASSIGN(HttpStreamFactoryImpl); 122 DISALLOW_COPY_AND_ASSIGN(HttpStreamFactoryImpl);
127 }; 123 };
128 124
129 } // namespace net 125 } // namespace net
130 126
131 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_H_ 127 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_H_
OLDNEW
« no previous file with comments | « net/http/http_stream_factory.h ('k') | net/http/http_stream_factory_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698