OLD | NEW |
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/browser/service_worker/service_worker_url_request_job.h" | 5 #include "content/browser/service_worker/service_worker_url_request_job.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
11 #include <string> | 11 #include <string> |
12 #include <utility> | 12 #include <utility> |
13 #include <vector> | 13 #include <vector> |
14 | 14 |
15 #include "base/bind.h" | 15 #include "base/bind.h" |
16 #include "base/callback.h" | 16 #include "base/callback.h" |
17 #include "base/callback_helpers.h" | 17 #include "base/callback_helpers.h" |
18 #include "base/files/file_util.h" | 18 #include "base/files/file_util.h" |
19 #include "base/guid.h" | 19 #include "base/guid.h" |
20 #include "base/location.h" | 20 #include "base/location.h" |
21 #include "base/numerics/safe_conversions.h" | 21 #include "base/numerics/safe_conversions.h" |
22 #include "base/single_thread_task_runner.h" | 22 #include "base/single_thread_task_runner.h" |
23 #include "base/strings/stringprintf.h" | 23 #include "base/strings/stringprintf.h" |
24 #include "base/task_runner.h" | 24 #include "base/task_runner.h" |
25 #include "base/task_runner_util.h" | 25 #include "base/task_runner_util.h" |
| 26 #include "base/threading/sequenced_worker_pool.h" |
26 #include "base/threading/thread_task_runner_handle.h" | 27 #include "base/threading/thread_task_runner_handle.h" |
27 #include "base/time/time.h" | 28 #include "base/time/time.h" |
28 #include "content/browser/resource_context_impl.h" | 29 #include "content/browser/resource_context_impl.h" |
29 #include "content/browser/service_worker/embedded_worker_instance.h" | 30 #include "content/browser/service_worker/embedded_worker_instance.h" |
30 #include "content/browser/service_worker/service_worker_blob_reader.h" | 31 #include "content/browser/service_worker/service_worker_blob_reader.h" |
31 #include "content/browser/service_worker/service_worker_fetch_dispatcher.h" | 32 #include "content/browser/service_worker/service_worker_fetch_dispatcher.h" |
32 #include "content/browser/service_worker/service_worker_provider_host.h" | 33 #include "content/browser/service_worker/service_worker_provider_host.h" |
33 #include "content/browser/service_worker/service_worker_response_info.h" | 34 #include "content/browser/service_worker/service_worker_response_info.h" |
34 #include "content/browser/service_worker/service_worker_stream_reader.h" | 35 #include "content/browser/service_worker/service_worker_stream_reader.h" |
35 #include "content/common/resource_request_body_impl.h" | 36 #include "content/common/resource_request_body_impl.h" |
(...skipping 871 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
907 DCHECK(!reported_navigation_preload_metrics_); | 908 DCHECK(!reported_navigation_preload_metrics_); |
908 reported_navigation_preload_metrics_ = true; | 909 reported_navigation_preload_metrics_ = true; |
909 | 910 |
910 ServiceWorkerMetrics::RecordNavigationPreloadResponse( | 911 ServiceWorkerMetrics::RecordNavigationPreloadResponse( |
911 worker_ready_time_ - worker_start_time_, | 912 worker_ready_time_ - worker_start_time_, |
912 navigation_preload_response_time_ - worker_start_time_, | 913 navigation_preload_response_time_ - worker_start_time_, |
913 initial_worker_status_, worker_start_situation_); | 914 initial_worker_status_, worker_start_situation_); |
914 } | 915 } |
915 | 916 |
916 } // namespace content | 917 } // namespace content |
OLD | NEW |