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

Side by Side Diff: content/child/web_url_loader_impl.cc

Issue 1146253004: Add workerReady timing for ServiceWorker controlled requests [2/3] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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 | « content/child/resource_dispatcher.cc ('k') | content/common/resource_messages.h » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "content/child/web_url_loader_impl.h" 5 #include "content/child/web_url_loader_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <deque> 8 #include <deque>
9 #include <string> 9 #include <string>
10 10
(...skipping 976 matching lines...) Expand 10 before | Expand all | Expand 10 after
987 987
988 // If there's no received headers end time, don't set load timing. This is 988 // If there's no received headers end time, don't set load timing. This is
989 // the case for non-HTTP requests, requests that don't go over the wire, and 989 // the case for non-HTTP requests, requests that don't go over the wire, and
990 // certain error cases. 990 // certain error cases.
991 if (!info.load_timing.receive_headers_end.is_null()) { 991 if (!info.load_timing.receive_headers_end.is_null()) {
992 WebURLLoadTiming timing; 992 WebURLLoadTiming timing;
993 PopulateURLLoadTiming(info.load_timing, &timing); 993 PopulateURLLoadTiming(info.load_timing, &timing);
994 const TimeTicks kNullTicks; 994 const TimeTicks kNullTicks;
995 timing.setWorkerStart( 995 timing.setWorkerStart(
996 (info.service_worker_start_time - kNullTicks).InSecondsF()); 996 (info.service_worker_start_time - kNullTicks).InSecondsF());
997 timing.setWorkerReady(
998 (info.service_worker_ready_time - kNullTicks).InSecondsF());
997 response->setLoadTiming(timing); 999 response->setLoadTiming(timing);
998 } 1000 }
999 1001
1000 if (info.devtools_info.get()) { 1002 if (info.devtools_info.get()) {
1001 WebHTTPLoadInfo load_info; 1003 WebHTTPLoadInfo load_info;
1002 1004
1003 load_info.setHTTPStatusCode(info.devtools_info->http_status_code); 1005 load_info.setHTTPStatusCode(info.devtools_info->http_status_code);
1004 load_info.setHTTPStatusText(WebString::fromLatin1( 1006 load_info.setHTTPStatusText(WebString::fromLatin1(
1005 info.devtools_info->http_status_text)); 1007 info.devtools_info->http_status_text));
1006 load_info.setEncodedDataLength(info.encoded_data_length); 1008 load_info.setEncodedDataLength(info.encoded_data_length);
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
1115 int intra_priority_value) { 1117 int intra_priority_value) {
1116 context_->DidChangePriority(new_priority, intra_priority_value); 1118 context_->DidChangePriority(new_priority, intra_priority_value);
1117 } 1119 }
1118 1120
1119 bool WebURLLoaderImpl::attachThreadedDataReceiver( 1121 bool WebURLLoaderImpl::attachThreadedDataReceiver(
1120 blink::WebThreadedDataReceiver* threaded_data_receiver) { 1122 blink::WebThreadedDataReceiver* threaded_data_receiver) {
1121 return context_->AttachThreadedDataReceiver(threaded_data_receiver); 1123 return context_->AttachThreadedDataReceiver(threaded_data_receiver);
1122 } 1124 }
1123 1125
1124 } // namespace content 1126 } // namespace content
OLDNEW
« no previous file with comments | « content/child/resource_dispatcher.cc ('k') | content/common/resource_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698