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

Unified Diff: content/browser/background_sync/background_sync_manager.cc

Issue 2218943002: Introduce ServiceWorker.EventDispatchingDelay UMA (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: incorporated mpearson@'s comment Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/browser/service_worker/embedded_worker_test_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/background_sync/background_sync_manager.cc
diff --git a/content/browser/background_sync/background_sync_manager.cc b/content/browser/background_sync/background_sync_manager.cc
index 072734f4f8b88dfdd7cb3cc30b144b8981c19bba..f9d819a709c407e8509b7ea8b200b9cb4beb5ee2 100644
--- a/content/browser/background_sync/background_sync_manager.cc
+++ b/content/browser/background_sync/background_sync_manager.cc
@@ -13,6 +13,7 @@
#include "base/single_thread_task_runner.h"
#include "base/threading/thread_task_runner_handle.h"
#include "base/time/default_clock.h"
+#include "base/time/time.h"
#include "build/build_config.h"
#include "content/browser/background_sync/background_sync_metrics.h"
#include "content/browser/background_sync/background_sync_network_observer.h"
@@ -149,10 +150,12 @@ std::unique_ptr<BackgroundSyncParameters> GetControllerParameters(
void OnSyncEventFinished(scoped_refptr<ServiceWorkerVersion> active_version,
int request_id,
const ServiceWorkerVersion::StatusCallback& callback,
- blink::mojom::ServiceWorkerEventStatus status) {
+ blink::mojom::ServiceWorkerEventStatus status,
+ double dispatch_event_time) {
if (!active_version->FinishRequest(
request_id,
- status == blink::mojom::ServiceWorkerEventStatus::COMPLETED)) {
+ status == blink::mojom::ServiceWorkerEventStatus::COMPLETED,
+ base::Time::FromDoubleT(dispatch_event_time))) {
return;
}
callback.Run(mojo::ConvertTo<ServiceWorkerStatusCode>(status));
« no previous file with comments | « no previous file | content/browser/service_worker/embedded_worker_test_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698