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 #ifndef NET_BASE_LOAD_TIMING_INFO_H_ | 5 #ifndef NET_BASE_LOAD_TIMING_INFO_H_ |
6 #define NET_BASE_LOAD_TIMING_INFO_H_ | 6 #define NET_BASE_LOAD_TIMING_INFO_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/time/time.h" | 9 #include "base/time/time.h" |
10 #include "net/base/net_export.h" | 10 #include "net/base/net_export.h" |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
84 base::TimeTicks connect_start; | 84 base::TimeTicks connect_start; |
85 base::TimeTicks connect_end; | 85 base::TimeTicks connect_end; |
86 | 86 |
87 // The time when the SSL handshake started / completed. For non-HTTPS | 87 // The time when the SSL handshake started / completed. For non-HTTPS |
88 // requests these are null. These times are only for the SSL connection to | 88 // requests these are null. These times are only for the SSL connection to |
89 // the final destination server, not an SSL/SPDY proxy. | 89 // the final destination server, not an SSL/SPDY proxy. |
90 base::TimeTicks ssl_start; | 90 base::TimeTicks ssl_start; |
91 base::TimeTicks ssl_end; | 91 base::TimeTicks ssl_end; |
92 }; | 92 }; |
93 | 93 |
94 // Contains the timing of ServiceWorker. | |
95 // These are all set by ServiceWrokerURLRequestJob. | |
96 struct NET_EXPORT_PRIVATE ServiceWorkerTiming { | |
mmenke
2014/09/02 19:10:43
It's a layering violation for net/ to know about S
shimazu
2014/09/04 03:32:41
Thanks for your comment, and I tried the implement
| |
97 ServiceWorkerTiming(); | |
98 ~ServiceWorkerTiming(); | |
99 | |
100 base::TimeTicks fetch_start; | |
101 base::TimeTicks fetch_ready; | |
102 base::TimeTicks fetch_end; | |
103 }; | |
104 | |
94 LoadTimingInfo(); | 105 LoadTimingInfo(); |
95 ~LoadTimingInfo(); | 106 ~LoadTimingInfo(); |
96 | 107 |
97 // True if the socket was reused. When true, DNS, connect, and SSL times | 108 // True if the socket was reused. When true, DNS, connect, and SSL times |
98 // will all be null. When false, those times may be null, too, for non-HTTP | 109 // will all be null. When false, those times may be null, too, for non-HTTP |
99 // requests, or when they don't apply to a request. | 110 // requests, or when they don't apply to a request. |
100 // | 111 // |
101 // For requests that are sent again after an AUTH challenge, this will be true | 112 // For requests that are sent again after an AUTH challenge, this will be true |
102 // if the original socket is reused, and false if a new socket is used. | 113 // if the original socket is reused, and false if a new socket is used. |
103 // Responding to a proxy AUTH challenge is never considered to be reusing a | 114 // Responding to a proxy AUTH challenge is never considered to be reusing a |
(...skipping 16 matching lines...) Expand all Loading... | |
120 // changes. | 131 // changes. |
121 base::Time request_start_time; | 132 base::Time request_start_time; |
122 | 133 |
123 base::TimeTicks request_start; | 134 base::TimeTicks request_start; |
124 | 135 |
125 // The time spent determing which proxy to use. Null when there is no PAC. | 136 // The time spent determing which proxy to use. Null when there is no PAC. |
126 base::TimeTicks proxy_resolve_start; | 137 base::TimeTicks proxy_resolve_start; |
127 base::TimeTicks proxy_resolve_end; | 138 base::TimeTicks proxy_resolve_end; |
128 | 139 |
129 ConnectTiming connect_timing; | 140 ConnectTiming connect_timing; |
141 ServiceWorkerTiming serviceworker_timing; | |
130 | 142 |
131 // The time that sending HTTP request started / ended. | 143 // The time that sending HTTP request started / ended. |
132 base::TimeTicks send_start; | 144 base::TimeTicks send_start; |
133 base::TimeTicks send_end; | 145 base::TimeTicks send_end; |
134 | 146 |
135 // The time at which the end of the HTTP headers were received. | 147 // The time at which the end of the HTTP headers were received. |
136 base::TimeTicks receive_headers_end; | 148 base::TimeTicks receive_headers_end; |
137 }; | 149 }; |
138 | 150 |
139 } // namespace net | 151 } // namespace net |
140 | 152 |
141 #endif // NET_BASE_LOAD_TIMING_INFO_H_ | 153 #endif // NET_BASE_LOAD_TIMING_INFO_H_ |
OLD | NEW |