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/http/http_network_transaction.h" | 5 #include "net/http/http_network_transaction.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 1099 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1110 | 1110 |
1111 UMA_HISTOGRAM_CUSTOM_TIMES("Net.Transaction_Latency_b", duration, | 1111 UMA_HISTOGRAM_CUSTOM_TIMES("Net.Transaction_Latency_b", duration, |
1112 base::TimeDelta::FromMilliseconds(1), | 1112 base::TimeDelta::FromMilliseconds(1), |
1113 base::TimeDelta::FromMinutes(10), | 1113 base::TimeDelta::FromMinutes(10), |
1114 100); | 1114 100); |
1115 UMA_HISTOGRAM_CUSTOM_TIMES("Net.Transaction_Latency_Total", | 1115 UMA_HISTOGRAM_CUSTOM_TIMES("Net.Transaction_Latency_Total", |
1116 total_duration, | 1116 total_duration, |
1117 base::TimeDelta::FromMilliseconds(1), | 1117 base::TimeDelta::FromMilliseconds(1), |
1118 base::TimeDelta::FromMinutes(10), 100); | 1118 base::TimeDelta::FromMinutes(10), 100); |
1119 | 1119 |
1120 static const bool use_warm_socket_impact_histogram = | |
1121 base::FieldTrialList::TrialExists("WarmSocketImpact"); | |
1122 if (use_warm_socket_impact_histogram) { | |
1123 UMA_HISTOGRAM_CUSTOM_TIMES( | |
1124 base::FieldTrial::MakeName("Net.Transaction_Latency_b", | |
1125 "WarmSocketImpact"), | |
1126 duration, | |
1127 base::TimeDelta::FromMilliseconds(1), | |
1128 base::TimeDelta::FromMinutes(10), | |
1129 100); | |
1130 UMA_HISTOGRAM_CUSTOM_TIMES( | |
1131 base::FieldTrial::MakeName("Net.Transaction_Latency_Total", | |
1132 "WarmSocketImpact"), | |
1133 total_duration, | |
1134 base::TimeDelta::FromMilliseconds(1), | |
1135 base::TimeDelta::FromMinutes(10), 100); | |
1136 } | |
1137 | |
1138 if (!stream_->IsConnectionReused()) { | 1120 if (!stream_->IsConnectionReused()) { |
1139 UMA_HISTOGRAM_CUSTOM_TIMES( | 1121 UMA_HISTOGRAM_CUSTOM_TIMES( |
1140 "Net.Transaction_Latency_Total_New_Connection", | 1122 "Net.Transaction_Latency_Total_New_Connection", |
1141 total_duration, base::TimeDelta::FromMilliseconds(1), | 1123 total_duration, base::TimeDelta::FromMilliseconds(1), |
1142 base::TimeDelta::FromMinutes(10), 100); | 1124 base::TimeDelta::FromMinutes(10), 100); |
1143 } | 1125 } |
1144 } | 1126 } |
1145 | 1127 |
1146 int HttpNetworkTransaction::HandleCertificateRequest(int error) { | 1128 int HttpNetworkTransaction::HandleCertificateRequest(int error) { |
1147 // There are two paths through which the server can request a certificate | 1129 // There are two paths through which the server can request a certificate |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1461 description = base::StringPrintf("Unknown state 0x%08X (%u)", state, | 1443 description = base::StringPrintf("Unknown state 0x%08X (%u)", state, |
1462 state); | 1444 state); |
1463 break; | 1445 break; |
1464 } | 1446 } |
1465 return description; | 1447 return description; |
1466 } | 1448 } |
1467 | 1449 |
1468 #undef STATE_CASE | 1450 #undef STATE_CASE |
1469 | 1451 |
1470 } // namespace net | 1452 } // namespace net |
OLD | NEW |