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

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

Issue 2595413002: Race preconnects to HTTP2 proxies that support alternate proxies
Patch Set: Rebased, rch comments Created 3 years, 11 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 #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 <memory> 8 #include <memory>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 // Tells |this| that |delegate_| has determined it still needs to continue 208 // Tells |this| that |delegate_| has determined it still needs to continue
209 // connecting. 209 // connecting.
210 virtual void Resume(); 210 virtual void Resume();
211 211
212 // Called to detach |this| Job. May resume the other Job, will disconnect 212 // Called to detach |this| Job. May resume the other Job, will disconnect
213 // the socket for |this| Job, and notify |delegate| upon completion. 213 // the socket for |this| Job, and notify |delegate| upon completion.
214 void Orphan(); 214 void Orphan();
215 215
216 void SetPriority(RequestPriority priority); 216 void SetPriority(RequestPriority priority);
217 217
218 // Sets |num_streams_| to 1 for preconnect jobs.
219 void RestrictNumStreamsToOne();
220
218 RequestPriority priority() const { return priority_; } 221 RequestPriority priority() const { return priority_; }
219 bool was_alpn_negotiated() const; 222 bool was_alpn_negotiated() const;
220 NextProto negotiated_protocol() const; 223 NextProto negotiated_protocol() const;
221 bool using_spdy() const; 224 bool using_spdy() const;
222 const NetLogWithSource& net_log() const { return net_log_; } 225 const NetLogWithSource& net_log() const { return net_log_; }
223 HttpStreamRequest::StreamType stream_type() const { return stream_type_; } 226 HttpStreamRequest::StreamType stream_type() const { return stream_type_; }
224 227
225 std::unique_ptr<HttpStream> ReleaseStream() { return std::move(stream_); } 228 std::unique_ptr<HttpStream> ReleaseStream() { return std::move(stream_); }
226 229
227 void SetStream(HttpStream* http_stream) { stream_.reset(http_stream); } 230 void SetStream(HttpStream* http_stream) { stream_.reset(http_stream); }
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after
526 const SSLConfig& server_ssl_config, 529 const SSLConfig& server_ssl_config,
527 const SSLConfig& proxy_ssl_config, 530 const SSLConfig& proxy_ssl_config,
528 HostPortPair destination, 531 HostPortPair destination,
529 GURL origin_url, 532 GURL origin_url,
530 NetLog* net_log) = 0; 533 NetLog* net_log) = 0;
531 }; 534 };
532 535
533 } // namespace net 536 } // namespace net
534 537
535 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ 538 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698