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_QUIC_QUIC_PROTOCOL_H_ | 5 #ifndef NET_QUIC_QUIC_PROTOCOL_H_ |
6 #define NET_QUIC_QUIC_PROTOCOL_H_ | 6 #define NET_QUIC_QUIC_PROTOCOL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <limits> | 9 #include <limits> |
10 #include <list> | 10 #include <list> |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 // Maximum size of the congestion window, in packets, for TCP congestion control | 69 // Maximum size of the congestion window, in packets, for TCP congestion control |
70 // algorithms. | 70 // algorithms. |
71 const size_t kMaxTcpCongestionWindow = 200; | 71 const size_t kMaxTcpCongestionWindow = 200; |
72 | 72 |
73 // Default size of the socket receive buffer in bytes. | 73 // Default size of the socket receive buffer in bytes. |
74 const QuicByteCount kDefaultSocketReceiveBuffer = 256 * 1024; | 74 const QuicByteCount kDefaultSocketReceiveBuffer = 256 * 1024; |
75 // Minimum size of the socket receive buffer in bytes. | 75 // Minimum size of the socket receive buffer in bytes. |
76 // Smaller values are ignored. | 76 // Smaller values are ignored. |
77 const QuicByteCount kMinSocketReceiveBuffer = 16 * 1024; | 77 const QuicByteCount kMinSocketReceiveBuffer = 16 * 1024; |
78 | 78 |
| 79 // Don't allow a client to suggest an RTT shorter than 10ms. |
| 80 const uint32 kMinInitialRoundTripTimeUs = 10 * kNumMicrosPerMilli; |
| 81 |
79 // Don't allow a client to suggest an RTT longer than 15 seconds. | 82 // Don't allow a client to suggest an RTT longer than 15 seconds. |
80 const uint32 kMaxInitialRoundTripTimeUs = 15 * kNumMicrosPerSecond; | 83 const uint32 kMaxInitialRoundTripTimeUs = 15 * kNumMicrosPerSecond; |
81 | 84 |
82 // Maximum number of open streams per connection. | 85 // Maximum number of open streams per connection. |
83 const size_t kDefaultMaxStreamsPerConnection = 100; | 86 const size_t kDefaultMaxStreamsPerConnection = 100; |
84 | 87 |
85 // Number of bytes reserved for public flags in the packet header. | 88 // Number of bytes reserved for public flags in the packet header. |
86 const size_t kPublicFlagsSize = 1; | 89 const size_t kPublicFlagsSize = 1; |
87 // Number of bytes reserved for version number in the packet header. | 90 // Number of bytes reserved for version number in the packet header. |
88 const size_t kQuicVersionSize = 4; | 91 const size_t kQuicVersionSize = 4; |
(...skipping 1002 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1091 SequenceNumberList* all_transmissions; | 1094 SequenceNumberList* all_transmissions; |
1092 // In flight packets have not been abandoned or lost. | 1095 // In flight packets have not been abandoned or lost. |
1093 bool in_flight; | 1096 bool in_flight; |
1094 // True if the packet can never be acked, so it can be removed. | 1097 // True if the packet can never be acked, so it can be removed. |
1095 bool is_unackable; | 1098 bool is_unackable; |
1096 }; | 1099 }; |
1097 | 1100 |
1098 } // namespace net | 1101 } // namespace net |
1099 | 1102 |
1100 #endif // NET_QUIC_QUIC_PROTOCOL_H_ | 1103 #endif // NET_QUIC_QUIC_PROTOCOL_H_ |
OLD | NEW |