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 #include "net/quic/chromium/quic_chromium_client_session.h" | 5 #include "net/quic/chromium/quic_chromium_client_session.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/callback_helpers.h" | 9 #include "base/callback_helpers.h" |
10 #include "base/location.h" | 10 #include "base/location.h" |
(...skipping 901 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
912 logger_->OnCryptoHandshakeMessageSent(message); | 912 logger_->OnCryptoHandshakeMessageSent(message); |
913 } | 913 } |
914 | 914 |
915 void QuicChromiumClientSession::OnCryptoHandshakeMessageReceived( | 915 void QuicChromiumClientSession::OnCryptoHandshakeMessageReceived( |
916 const CryptoHandshakeMessage& message) { | 916 const CryptoHandshakeMessage& message) { |
917 logger_->OnCryptoHandshakeMessageReceived(message); | 917 logger_->OnCryptoHandshakeMessageReceived(message); |
918 if (message.tag() == kREJ || message.tag() == kSREJ) { | 918 if (message.tag() == kREJ || message.tag() == kSREJ) { |
919 UMA_HISTOGRAM_CUSTOM_COUNTS("Net.QuicSession.RejectLength", | 919 UMA_HISTOGRAM_CUSTOM_COUNTS("Net.QuicSession.RejectLength", |
920 message.GetSerialized().length(), 1000, 10000, | 920 message.GetSerialized().length(), 1000, 10000, |
921 50); | 921 50); |
922 base::StringPiece proof; | 922 QuicStringPiece proof; |
923 UMA_HISTOGRAM_BOOLEAN("Net.QuicSession.RejectHasProof", | 923 UMA_HISTOGRAM_BOOLEAN("Net.QuicSession.RejectHasProof", |
924 message.GetStringPiece(kPROF, &proof)); | 924 message.GetStringPiece(kPROF, &proof)); |
925 } | 925 } |
926 } | 926 } |
927 | 927 |
928 void QuicChromiumClientSession::OnGoAway(const QuicGoAwayFrame& frame) { | 928 void QuicChromiumClientSession::OnGoAway(const QuicGoAwayFrame& frame) { |
929 QuicSession::OnGoAway(frame); | 929 QuicSession::OnGoAway(frame); |
930 NotifyFactoryOfSessionGoingAway(); | 930 NotifyFactoryOfSessionGoingAway(); |
931 port_migration_detected_ = frame.error_code == QUIC_ERROR_MIGRATING_PORT; | 931 port_migration_detected_ = frame.error_code == QUIC_ERROR_MIGRATING_PORT; |
932 } | 932 } |
(...skipping 587 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1520 } | 1520 } |
1521 | 1521 |
1522 size_t QuicChromiumClientSession::EstimateMemoryUsage() const { | 1522 size_t QuicChromiumClientSession::EstimateMemoryUsage() const { |
1523 // TODO(xunjieli): Estimate |crypto_stream_|, QuicSpdySession's | 1523 // TODO(xunjieli): Estimate |crypto_stream_|, QuicSpdySession's |
1524 // QuicHeaderList, QuicSession's QuiCWriteBlockedList, open streams and | 1524 // QuicHeaderList, QuicSession's QuiCWriteBlockedList, open streams and |
1525 // unacked packet map. | 1525 // unacked packet map. |
1526 return base::trace_event::EstimateMemoryUsage(packet_readers_); | 1526 return base::trace_event::EstimateMemoryUsage(packet_readers_); |
1527 } | 1527 } |
1528 | 1528 |
1529 } // namespace net | 1529 } // namespace net |
OLD | NEW |