@@ -116,51 +116,41 @@ QuicSocketBase::GetTypeId (void)
116
116
UintegerValue (2 ), // according to the QUIC RFC this value should default to 0, and be increased by the client/server
117
117
MakeUintegerAccessor (&QuicSocketBase::m_initial_max_stream_id_bidi),
118
118
MakeUintegerChecker<uint32_t > ())
119
- .AddAttribute (
120
- " MaxStreamIdUni" , " Maximum StreamId for Unidirectional Streams" ,
121
- UintegerValue (2 ), // according to the QUIC RFC this value should default to 0, and be increased by the client/server
122
- MakeUintegerAccessor (&QuicSocketBase::m_initial_max_stream_id_uni),
123
- MakeUintegerChecker<uint32_t > ())
124
- .AddAttribute (
125
- " MaxTrackedGaps" , " Maximum number of gaps in an ACK" ,
126
- UintegerValue (20 ),
127
- MakeUintegerAccessor (&QuicSocketBase::m_maxTrackedGaps),
128
- MakeUintegerChecker<uint32_t > ())
129
- .AddAttribute (
130
- " OmitConnectionId" ,
131
- " Omit ConnectionId field in Short QuicHeader format" ,
132
- BooleanValue (false ),
133
- MakeBooleanAccessor (&QuicSocketBase::m_omit_connection_id),
134
- MakeBooleanChecker ())
135
- .AddAttribute (
136
- " MaxPacketSize" ,
137
- " Maximum Packet Size" ,
138
- UintegerValue (1460 ),
139
- MakeUintegerAccessor (&QuicSocketBase::GetSegSize,
140
- &QuicSocketBase::SetSegSize),
141
- MakeUintegerChecker<uint16_t > ())
142
- .AddAttribute (
143
- " SocketSndBufSize" ,
144
- " QuicSocketBase maximum transmit buffer size (bytes)" ,
145
- UintegerValue (131072 ), // 128k
146
- MakeUintegerAccessor (&QuicSocketBase::GetSocketSndBufSize,
147
- &QuicSocketBase::SetSocketSndBufSize),
148
- MakeUintegerChecker<uint32_t > ())
149
- .AddAttribute (
150
- " SocketRcvBufSize" ,
151
- " QuicSocketBase maximum receive buffer size (bytes)" ,
152
- UintegerValue (131072 ), // 128k
153
- MakeUintegerAccessor (&QuicSocketBase::GetSocketRcvBufSize,
154
- &QuicSocketBase::SetSocketRcvBufSize),
155
- MakeUintegerChecker<uint32_t > ())
119
+ .AddAttribute (" MaxStreamIdUni" , " Maximum StreamId for Unidirectional Streams" ,
120
+ UintegerValue (2 ), // according to the QUIC RFC this value should default to 0, and be increased by the client/server
121
+ MakeUintegerAccessor (&QuicSocketBase::m_initial_max_stream_id_uni),
122
+ MakeUintegerChecker<uint32_t > ())
123
+ .AddAttribute (" MaxTrackedGaps" , " Maximum number of gaps in an ACK" ,
124
+ UintegerValue (20 ),
125
+ MakeUintegerAccessor (&QuicSocketBase::m_maxTrackedGaps),
126
+ MakeUintegerChecker<uint32_t > ())
127
+ .AddAttribute (" OmitConnectionId" , " Omit ConnectionId field in Short QuicHeader format" ,
128
+ BooleanValue (false ),
129
+ MakeBooleanAccessor (&QuicSocketBase::m_omit_connection_id),
130
+ MakeBooleanChecker ())
131
+ .AddAttribute (" MaxPacketSize" , " Maximum Packet Size" ,
132
+ UintegerValue (1460 ),
133
+ MakeUintegerAccessor (&QuicSocketBase::GetSegSize,
134
+ &QuicSocketBase::SetSegSize),
135
+ MakeUintegerChecker<uint16_t > ())
136
+ .AddAttribute (" SocketSndBufSize" , " QuicSocketBase maximum transmit buffer size (bytes)" ,
137
+ UintegerValue (131072 ), // 128k
138
+ MakeUintegerAccessor (&QuicSocketBase::GetSocketSndBufSize,
139
+ &QuicSocketBase::SetSocketSndBufSize),
140
+ MakeUintegerChecker<uint32_t > ())
141
+ .AddAttribute (" SocketRcvBufSize" , " QuicSocketBase maximum receive buffer size (bytes)" ,
142
+ UintegerValue (131072 ), // 128k
143
+ MakeUintegerAccessor (&QuicSocketBase::GetSocketRcvBufSize,
144
+ &QuicSocketBase::SetSocketRcvBufSize),
145
+ MakeUintegerChecker<uint32_t > ())
156
146
// .AddAttribute ("StatelessResetToken, "Stateless Reset Token",
157
147
// UintegerValue (0),
158
148
// MakeUintegerAccessor (&QuicSocketBase::m_stateless_reset_token),
159
149
// MakeUintegerChecker<uint128_t> ())
160
- .AddAttribute (
161
- " AckDelayExponent " , " Ack Delay Exponent " , UintegerValue (3 ),
162
- MakeUintegerAccessor (&QuicSocketBase::m_ack_delay_exponent),
163
- MakeUintegerChecker<uint8_t > ())
150
+ .AddAttribute (" AckDelayExponent " , " Ack Delay Exponent " ,
151
+ UintegerValue (3 ),
152
+ MakeUintegerAccessor (&QuicSocketBase::m_ack_delay_exponent),
153
+ MakeUintegerChecker<uint8_t > ())
164
154
.AddAttribute (" FlushOnClose" , " Determines the connection close behavior" ,
165
155
BooleanValue (true ),
166
156
MakeBooleanAccessor (&QuicSocketBase::m_flushOnClose),
@@ -170,46 +160,34 @@ QuicSocketBase::GetTypeId (void)
170
160
UintegerValue (2 ),
171
161
MakeUintegerAccessor (&QuicSocketState::m_kMaxTLPs),
172
162
MakeUintegerChecker<uint32_t > ())
173
- .AddAttribute (
174
- " kReorderingThreshold" ,
175
- " Maximum reordering in packet number space before FACK style loss detection considers a packet lost" ,
176
- UintegerValue (3 ),
177
- MakeUintegerAccessor (&QuicSocketState::m_kReorderingThreshold),
178
- MakeUintegerChecker<uint32_t > ())
179
- .AddAttribute (
180
- " kTimeReorderingFraction" ,
181
- " Maximum reordering in time space before time based loss detection considers a packet lost" ,
182
- DoubleValue (9 / 8 ),
183
- MakeDoubleAccessor (&QuicSocketState::m_kTimeReorderingFraction),
184
- MakeDoubleChecker<double > (0 ))
185
- .AddAttribute (
186
- " kUsingTimeLossDetection" ,
187
- " Whether time based loss detection is in use" , BooleanValue (false ),
188
- MakeBooleanAccessor (&QuicSocketState::m_kUsingTimeLossDetection),
189
- MakeBooleanChecker ())
190
- .AddAttribute (
191
- " kMinTLPTimeout" ,
192
- " Minimum time in the future a tail loss probe alarm may be set for" ,
193
- TimeValue (MilliSeconds (10 )),
194
- MakeTimeAccessor (&QuicSocketState::m_kMinTLPTimeout),
195
- MakeTimeChecker ())
196
- .AddAttribute (
197
- " kMinRTOTimeout" ,
198
- " Minimum time in the future an RTO alarm may be set for" ,
199
- TimeValue (MilliSeconds (200 )),
200
- MakeTimeAccessor (&QuicSocketState::m_kMinRTOTimeout),
201
- MakeTimeChecker ())
202
- .AddAttribute (
203
- " kDelayedAckTimeout" , " The length of the peer's delayed ACK timer" ,
204
- TimeValue (MilliSeconds (25 )),
205
- MakeTimeAccessor (&QuicSocketState::m_kDelayedAckTimeout),
206
- MakeTimeChecker ())
207
- .AddAttribute (
208
- " kDefaultInitialRtt" ,
209
- " The default RTT used before an RTT sample is taken" ,
210
- TimeValue (MilliSeconds (100 )),
211
- MakeTimeAccessor (&QuicSocketState::m_kDefaultInitialRtt),
212
- MakeTimeChecker ())
163
+ .AddAttribute (" kReorderingThreshold" , " Maximum reordering in packet number space before FACK style loss detection considers a packet lost" ,
164
+ UintegerValue (3 ),
165
+ MakeUintegerAccessor (&QuicSocketState::m_kReorderingThreshold),
166
+ MakeUintegerChecker<uint32_t > ())
167
+ .AddAttribute (" kTimeReorderingFraction" , " Maximum reordering in time space before time based loss detection considers a packet lost" ,
168
+ DoubleValue (9 / 8 ),
169
+ MakeDoubleAccessor (&QuicSocketState::m_kTimeReorderingFraction),
170
+ MakeDoubleChecker<double > (0 ))
171
+ .AddAttribute (" kUsingTimeLossDetection" , " Whether time based loss detection is in use" ,
172
+ BooleanValue (false ),
173
+ MakeBooleanAccessor (&QuicSocketState::m_kUsingTimeLossDetection),
174
+ MakeBooleanChecker ())
175
+ .AddAttribute (" kMinTLPTimeout" , " Minimum time in the future a tail loss probe alarm may be set for" ,
176
+ TimeValue (MilliSeconds (10 )),
177
+ MakeTimeAccessor (&QuicSocketState::m_kMinTLPTimeout),
178
+ MakeTimeChecker ())
179
+ .AddAttribute (" kMinRTOTimeout" , " Minimum time in the future an RTO alarm may be set for" ,
180
+ TimeValue (MilliSeconds (200 )),
181
+ MakeTimeAccessor (&QuicSocketState::m_kMinRTOTimeout),
182
+ MakeTimeChecker ())
183
+ .AddAttribute (" kDelayedAckTimeout" , " The length of the peer's delayed ACK timer" ,
184
+ TimeValue (MilliSeconds (25 )),
185
+ MakeTimeAccessor (&QuicSocketState::m_kDelayedAckTimeout),
186
+ MakeTimeChecker ())
187
+ .AddAttribute (" kDefaultInitialRtt" , " The default RTT used before an RTT sample is taken" ,
188
+ TimeValue (MilliSeconds (100 )),
189
+ MakeTimeAccessor (&QuicSocketState::m_kDefaultInitialRtt),
190
+ MakeTimeChecker ())
213
191
.AddAttribute (" InitialSlowStartThreshold" ,
214
192
" QUIC initial slow start threshold (bytes)" ,
215
193
UintegerValue (INT32_MAX),
@@ -233,12 +211,15 @@ QuicSocketBase::GetTypeId (void)
233
211
TimeValue (MilliSeconds (100 )),
234
212
MakeTimeAccessor (&QuicSocketBase::m_defaultLatency),
235
213
MakeTimeChecker ())
236
- .AddAttribute (
237
- " LegacyCongestionControl" ,
238
- " When true, use TCP implementations for the congestion control" ,
239
- BooleanValue (false ),
240
- MakeBooleanAccessor (&QuicSocketBase::m_quicCongestionControlLegacy),
241
- MakeBooleanChecker ())
214
+ .AddAttribute (" LegacyCongestionControl" , " When true, use TCP implementations for the congestion control" ,
215
+ BooleanValue (false ),
216
+ MakeBooleanAccessor (&QuicSocketBase::m_quicCongestionControlLegacy),
217
+ MakeBooleanChecker ())
218
+ .AddAttribute (" TCB" ,
219
+ " The connection's QuicSocketState" ,
220
+ PointerValue (),
221
+ MakePointerAccessor (&QuicSocketBase::m_tcb),
222
+ MakePointerChecker<QuicSocketState> ())
242
223
// .AddTraceSource ("RTO", "Retransmission timeout",
243
224
// MakeTraceSourceAccessor (&QuicSocketBase::m_rto),
244
225
// "ns3::Time::TracedValueCallback").AddTraceSource (
@@ -308,11 +289,6 @@ QuicSocketBase::GetTypeId (void)
308
289
" Receive QUIC packet from UDP protocol" ,
309
290
MakeTraceSourceAccessor (&QuicSocketBase::m_rxTrace),
310
291
" ns3::QuicSocketBase::QuicTxRxTracedCallback" )
311
- .AddAttribute (" TCB" ,
312
- " The connection's QuicSocketState" ,
313
- PointerValue (),
314
- MakePointerAccessor (&QuicSocketBase::m_tcb),
315
- MakePointerChecker<QuicSocketState> ())
316
292
;
317
293
return tid;
318
294
}
@@ -591,14 +567,13 @@ QuicSocketBase::QuicSocketBase (const QuicSocketBase& sock) // Copy constructo
591
567
m_quicCongestionControlLegacy (sock.m_quicCongestionControlLegacy),
592
568
m_queue_ack (sock.m_queue_ack),
593
569
m_numPacketsReceivedSinceLastAckSent (sock.m_numPacketsReceivedSinceLastAckSent),
570
+ m_lastMaxData(0 ),
571
+ m_maxDataInterval(10 ),
594
572
m_pacingTimer (Timer::REMOVE_ON_DESTROY),
595
573
m_txTrace (sock.m_txTrace),
596
574
m_rxTrace (sock.m_rxTrace)
597
575
{
598
576
NS_LOG_FUNCTION (this );
599
- NS_LOG_LOGIC (this << " invoked the copy constructor" );
600
- m_lastMaxData = 0 ;
601
- m_maxDataInterval = 10 ;
602
577
603
578
// Callback<void, Ptr< Socket > > vPS = MakeNullCallback<void, Ptr<Socket> > ();
604
579
// Callback<void, Ptr<Socket>, const Address &> vPSA = MakeNullCallback<void, Ptr<Socket>, const Address &> ();
0 commit comments