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

Side by Side Diff: net/tools/quic/end_to_end_test.cc

Issue 471613002: Change how QUIC negotiates pacing from congestion feedback to QUIC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Add_max_bandwidth_max_bandwidth_timestamp_73055131
Patch Set: Created 6 years, 4 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 #include <stddef.h> 5 #include <stddef.h>
6 #include <string> 6 #include <string>
7 #include <sys/epoll.h> 7 #include <sys/epoll.h>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after
285 GetSentPacketManagerFromFirstServerSession() const { 285 GetSentPacketManagerFromFirstServerSession() const {
286 QuicDispatcher* dispatcher = 286 QuicDispatcher* dispatcher =
287 QuicServerPeer::GetDispatcher(server_thread_->server()); 287 QuicServerPeer::GetDispatcher(server_thread_->server());
288 QuicSession* session = dispatcher->session_map().begin()->second; 288 QuicSession* session = dispatcher->session_map().begin()->second;
289 return &session->connection()->sent_packet_manager(); 289 return &session->connection()->sent_packet_manager();
290 } 290 }
291 291
292 bool Initialize() { 292 bool Initialize() {
293 QuicTagVector copt; 293 QuicTagVector copt;
294 294
295 if (GetParam().use_pacing) {
296 copt.push_back(kPACE);
297 }
298 server_config_.SetConnectionOptionsToSend(copt);
299
295 // TODO(nimia): Consider setting the congestion control algorithm for the 300 // TODO(nimia): Consider setting the congestion control algorithm for the
296 // client as well according to the test parameter. 301 // client as well according to the test parameter.
297 copt.push_back(GetParam().congestion_control_tag); 302 copt.push_back(GetParam().congestion_control_tag);
298 303
299 if (GetParam().use_fec) { 304 if (GetParam().use_fec) {
300 // Set FEC config in client's connection options and in client session. 305 // Set FEC config in client's connection options and in client session.
301 copt.push_back(kFHDR); 306 copt.push_back(kFHDR);
302 } 307 }
303 308
304 client_config_.SetConnectionOptionsToSend(copt); 309 client_config_.SetConnectionOptionsToSend(copt);
(...skipping 1074 matching lines...) Expand 10 before | Expand all | Expand 10 after
1379 QuicSession* session = dispatcher->session_map().begin()->second; 1384 QuicSession* session = dispatcher->session_map().begin()->second;
1380 EXPECT_EQ(0u, QuicSessionPeer::GetLocallyClosedStreamsHighestOffset( 1385 EXPECT_EQ(0u, QuicSessionPeer::GetLocallyClosedStreamsHighestOffset(
1381 session).size()); 1386 session).size());
1382 server_thread_->Resume(); 1387 server_thread_->Resume();
1383 } 1388 }
1384 1389
1385 } // namespace 1390 } // namespace
1386 } // namespace test 1391 } // namespace test
1387 } // namespace tools 1392 } // namespace tools
1388 } // namespace net 1393 } // namespace net
OLDNEW
« net/quic/quic_connection.cc ('K') | « net/quic/quic_stream_factory_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698