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

Side by Side Diff: net/quic/chromium/quic_stream_factory.cc

Issue 2840633002: Remove test-only method QuicStreamFactory::CreateFromSession() (Closed)
Patch Set: Created 3 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
« no previous file with comments | « net/quic/chromium/quic_stream_factory.h ('k') | net/quic/chromium/quic_stream_factory_peer.h » ('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 #include "net/quic/chromium/quic_stream_factory.h" 5 #include "net/quic/chromium/quic_stream_factory.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <tuple> 8 #include <tuple>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 1041 matching lines...) Expand 10 before | Expand all | Expand 10 after
1052 1052
1053 active_jobs_[server_id].clear(); 1053 active_jobs_[server_id].clear();
1054 active_jobs_.erase(server_id); 1054 active_jobs_.erase(server_id);
1055 job_requests_map_.erase(requests_iter); 1055 job_requests_map_.erase(requests_iter);
1056 } 1056 }
1057 1057
1058 void QuicStreamFactory::OnCertVerifyJobComplete(CertVerifierJob* job, int rv) { 1058 void QuicStreamFactory::OnCertVerifyJobComplete(CertVerifierJob* job, int rv) {
1059 active_cert_verifier_jobs_.erase(job->server_id()); 1059 active_cert_verifier_jobs_.erase(job->server_id());
1060 } 1060 }
1061 1061
1062 std::unique_ptr<QuicHttpStream> QuicStreamFactory::CreateFromSession(
1063 QuicChromiumClientSession* session) {
1064 return base::MakeUnique<QuicHttpStream>(session->GetWeakPtr(),
1065 http_server_properties_);
1066 }
1067
1068 void QuicStreamFactory::OnIdleSession(QuicChromiumClientSession* session) {} 1062 void QuicStreamFactory::OnIdleSession(QuicChromiumClientSession* session) {}
1069 1063
1070 void QuicStreamFactory::OnSessionGoingAway(QuicChromiumClientSession* session) { 1064 void QuicStreamFactory::OnSessionGoingAway(QuicChromiumClientSession* session) {
1071 const AliasSet& aliases = session_aliases_[session]; 1065 const AliasSet& aliases = session_aliases_[session];
1072 for (AliasSet::const_iterator it = aliases.begin(); it != aliases.end(); 1066 for (AliasSet::const_iterator it = aliases.begin(); it != aliases.end();
1073 ++it) { 1067 ++it) {
1074 const QuicServerId& server_id = it->server_id(); 1068 const QuicServerId& server_id = it->server_id();
1075 DCHECK(active_sessions_.count(server_id)); 1069 DCHECK(active_sessions_.count(server_id));
1076 DCHECK_EQ(session, active_sessions_[server_id]); 1070 DCHECK_EQ(session, active_sessions_[server_id]);
1077 // Track sessions which have recently gone away so that we can disable 1071 // Track sessions which have recently gone away so that we can disable
(...skipping 654 matching lines...) Expand 10 before | Expand all | Expand 10 after
1732 // Since the session was active, there's no longer an 1726 // Since the session was active, there's no longer an
1733 // HttpStreamFactoryImpl::Job running which can mark it broken, unless the TCP 1727 // HttpStreamFactoryImpl::Job running which can mark it broken, unless the TCP
1734 // job also fails. So to avoid not using QUIC when we otherwise could, we mark 1728 // job also fails. So to avoid not using QUIC when we otherwise could, we mark
1735 // it as recently broken, which means that 0-RTT will be disabled but we'll 1729 // it as recently broken, which means that 0-RTT will be disabled but we'll
1736 // still race. 1730 // still race.
1737 http_server_properties_->MarkAlternativeServiceRecentlyBroken( 1731 http_server_properties_->MarkAlternativeServiceRecentlyBroken(
1738 alternative_service); 1732 alternative_service);
1739 } 1733 }
1740 1734
1741 } // namespace net 1735 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/chromium/quic_stream_factory.h ('k') | net/quic/chromium/quic_stream_factory_peer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698