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

Side by Side Diff: net/quic/chromium/quic_connection_logger.cc

Issue 2239103002: Add histograms to record QUIC Min and Smoothed RTT. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: units Created 4 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
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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_connection_logger.h" 5 #include "net/quic/chromium/quic_connection_logger.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <memory> 9 #include <memory>
10 #include <utility> 10 #include <utility>
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 num_undecryptable_packets_); 320 num_undecryptable_packets_);
321 UMA_HISTOGRAM_COUNTS("Net.QuicSession.DuplicatePacketsReceived", 321 UMA_HISTOGRAM_COUNTS("Net.QuicSession.DuplicatePacketsReceived",
322 num_duplicate_packets_); 322 num_duplicate_packets_);
323 UMA_HISTOGRAM_COUNTS("Net.QuicSession.BlockedFrames.Received", 323 UMA_HISTOGRAM_COUNTS("Net.QuicSession.BlockedFrames.Received",
324 num_blocked_frames_received_); 324 num_blocked_frames_received_);
325 UMA_HISTOGRAM_COUNTS("Net.QuicSession.BlockedFrames.Sent", 325 UMA_HISTOGRAM_COUNTS("Net.QuicSession.BlockedFrames.Sent",
326 num_blocked_frames_sent_); 326 num_blocked_frames_sent_);
327 UMA_HISTOGRAM_COUNTS("Net.QuicSession.HeadersStream.EarlyFramesReceived", 327 UMA_HISTOGRAM_COUNTS("Net.QuicSession.HeadersStream.EarlyFramesReceived",
328 session_->headers_stream()->num_early_frames_received()); 328 session_->headers_stream()->num_early_frames_received());
329 329
330 const QuicConnectionStats& stats = session_->connection()->GetStats();
331 UMA_HISTOGRAM_TIMES("Net.QuicSession.MinRTT",
332 base::TimeDelta::FromMicroseconds(stats.min_rtt_us));
333 UMA_HISTOGRAM_TIMES("Net.QuicSession.SmoothedRTT",
334 base::TimeDelta::FromMicroseconds(stats.srtt_us));
335
330 if (num_frames_received_ > 0) { 336 if (num_frames_received_ > 0) {
331 int duplicate_stream_frame_per_thousand = 337 int duplicate_stream_frame_per_thousand =
332 num_duplicate_frames_received_ * 1000 / num_frames_received_; 338 num_duplicate_frames_received_ * 1000 / num_frames_received_;
333 if (num_packets_received_ < 100) { 339 if (num_packets_received_ < 100) {
334 UMA_HISTOGRAM_CUSTOM_COUNTS( 340 UMA_HISTOGRAM_CUSTOM_COUNTS(
335 "Net.QuicSession.StreamFrameDuplicatedShortConnection", 341 "Net.QuicSession.StreamFrameDuplicatedShortConnection",
336 duplicate_stream_frame_per_thousand, 1, 1000, 75); 342 duplicate_stream_frame_per_thousand, 1, 1000, 75);
337 } else { 343 } else {
338 UMA_HISTOGRAM_CUSTOM_COUNTS( 344 UMA_HISTOGRAM_CUSTOM_COUNTS(
339 "Net.QuicSession.StreamFrameDuplicatedLongConnection", 345 "Net.QuicSession.StreamFrameDuplicatedLongConnection",
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
844 continue; 850 continue;
845 } 851 }
846 // Record some overlapping patterns, to get a better picture, since this is 852 // Record some overlapping patterns, to get a better picture, since this is
847 // not very expensive. 853 // not very expensive.
848 if (i % 3 == 0) 854 if (i % 3 == 0)
849 six_packet_histogram->Add(recent_6_mask); 855 six_packet_histogram->Add(recent_6_mask);
850 } 856 }
851 } 857 }
852 858
853 } // namespace net 859 } // namespace net
OLDNEW
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698