| OLD | NEW |
| 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/quic_connection_logger.h" | 5 #include "net/quic/quic_connection_logger.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 } | 139 } |
| 140 case kFixRate: | 140 case kFixRate: |
| 141 dict->SetString("type", "FixRate"); | 141 dict->SetString("type", "FixRate"); |
| 142 dict->SetInteger("bitrate_in_bytes_per_second", | 142 dict->SetInteger("bitrate_in_bytes_per_second", |
| 143 frame->fix_rate.bitrate.ToBytesPerSecond()); | 143 frame->fix_rate.bitrate.ToBytesPerSecond()); |
| 144 break; | 144 break; |
| 145 case kTCP: | 145 case kTCP: |
| 146 dict->SetString("type", "TCP"); | 146 dict->SetString("type", "TCP"); |
| 147 dict->SetInteger("receive_window", frame->tcp.receive_window); | 147 dict->SetInteger("receive_window", frame->tcp.receive_window); |
| 148 break; | 148 break; |
| 149 case kTCPBBR: | |
| 150 dict->SetString("type", "TCPBBR"); | |
| 151 // TODO(rtenneti): Add support for BBR. | |
| 152 break; | |
| 153 } | 149 } |
| 154 | 150 |
| 155 return dict; | 151 return dict; |
| 156 } | 152 } |
| 157 | 153 |
| 158 base::Value* NetLogQuicRstStreamFrameCallback( | 154 base::Value* NetLogQuicRstStreamFrameCallback( |
| 159 const QuicRstStreamFrame* frame, | 155 const QuicRstStreamFrame* frame, |
| 160 NetLog::LogLevel /* log_level */) { | 156 NetLog::LogLevel /* log_level */) { |
| 161 base::DictionaryValue* dict = new base::DictionaryValue(); | 157 base::DictionaryValue* dict = new base::DictionaryValue(); |
| 162 dict->SetInteger("stream_id", frame->stream_id); | 158 dict->SetInteger("stream_id", frame->stream_id); |
| (...skipping 665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 828 continue; | 824 continue; |
| 829 } | 825 } |
| 830 // Record some overlapping patterns, to get a better picture, since this is | 826 // Record some overlapping patterns, to get a better picture, since this is |
| 831 // not very expensive. | 827 // not very expensive. |
| 832 if (i % 3 == 0) | 828 if (i % 3 == 0) |
| 833 six_packet_histogram->Add(recent_6_mask); | 829 six_packet_histogram->Add(recent_6_mask); |
| 834 } | 830 } |
| 835 } | 831 } |
| 836 | 832 |
| 837 } // namespace net | 833 } // namespace net |
| OLD | NEW |