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

Side by Side Diff: net/quic/core/quic_buffered_packet_store.h

Issue 2403983002: 35. relnote: Call QuicBufferedPacketStore::MaybeSetExpirationAlarm instead of setting alarm directl… (Closed)
Patch Set: Created 4 years, 2 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 | « no previous file | net/quic/core/quic_buffered_packet_store.cc » ('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) 2016 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2016 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_BUFFERED_PACKET_STORE_H_ 5 #ifndef NET_QUIC_QUIC_BUFFERED_PACKET_STORE_H_
6 #define NET_QUIC_QUIC_BUFFERED_PACKET_STORE_H_ 6 #define NET_QUIC_QUIC_BUFFERED_PACKET_STORE_H_
7 7
8 #include "net/base/ip_address.h" 8 #include "net/base/ip_address.h"
9 #include "net/base/linked_hash_map.h" 9 #include "net/base/linked_hash_map.h"
10 #include "net/base/net_export.h" 10 #include "net/base/net_export.h"
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 void MaybeSetExpirationAlarm(); 134 void MaybeSetExpirationAlarm();
135 135
136 // Return true if add an extra packet will go beyond allowed max connection 136 // Return true if add an extra packet will go beyond allowed max connection
137 // limit. The limit for non-CHLO packet and CHLO packet is different. 137 // limit. The limit for non-CHLO packet and CHLO packet is different.
138 bool ShouldBufferPacket(bool is_chlo); 138 bool ShouldBufferPacket(bool is_chlo);
139 139
140 // A map to store packet queues with creation time for each connection. 140 // A map to store packet queues with creation time for each connection.
141 BufferedPacketMap undecryptable_packets_; 141 BufferedPacketMap undecryptable_packets_;
142 142
143 // The max time the packets of a connection can be buffer in the store. 143 // The max time the packets of a connection can be buffer in the store.
144 QuicTime::Delta connection_life_span_; 144 const QuicTime::Delta connection_life_span_;
145 145
146 VisitorInterface* visitor_; // Unowned. 146 VisitorInterface* visitor_; // Unowned.
147 147
148 const QuicClock* clock_; // Unowned. 148 const QuicClock* clock_; // Unowned.
149 149
150 // This alarm fires every |connection_life_span_| to clean up 150 // This alarm fires every |connection_life_span_| to clean up
151 // packets staying in the store for too long. 151 // packets staying in the store for too long.
152 std::unique_ptr<QuicAlarm> expiration_alarm_; 152 std::unique_ptr<QuicAlarm> expiration_alarm_;
153 153
154 // Keeps track of connection with CHLO buffered up already and the order they 154 // Keeps track of connection with CHLO buffered up already and the order they
155 // arrive. 155 // arrive.
156 linked_hash_map<QuicConnectionId, bool> connections_with_chlo_; 156 linked_hash_map<QuicConnectionId, bool> connections_with_chlo_;
157 }; 157 };
158 158
159 } // namespace net 159 } // namespace net
160 160
161 #endif // NET_QUIC_QUIC_BUFFERED_PACKET_STORE_H_ 161 #endif // NET_QUIC_QUIC_BUFFERED_PACKET_STORE_H_
OLDNEW
« no previous file with comments | « no previous file | net/quic/core/quic_buffered_packet_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698