Skip to content
Commit 67f29a11 authored by Justin Lulejian's avatar Justin Lulejian Committed by Chromium LUCI CQ
Browse files

[Extensions] Fix service worker event dispatch metric emitting logic.

Regarding metrics:
Extensions.Events.DispatchToAckTime.ExtensionEventPage
Extensions.Events.DispatchToAckTime.ExtensionServiceWorker
Extensions.Events.DispatchToAckLongTime.ExtensionServiceWorker

Two issues are fixed here:

1) The .DeepCopy() for Event was not copying the dispatch_start_time and
causing the metrics to have the wrong value.
2) EventRouter::DispatchEventToSender() is now excluded from these
metrics as it is a different flow than
EventRouter::DispatchEventImpl(). Specifically it is past when a
service worker has been started so it was measuring a different value.

This means that the metrics are accurately measuring event dispatch
time, but no longer includes those going through
EventRouter::DispatchEventToSender(). Including that flow will be
considered in a follow-up change.

OBSOLETE_HISTOGRAMS=incremented
DispatchToAckTime/DispatchToAckLongTime.ExtensionServiceWorker and
DispatchToAck.ExtensionEventPage due to mostly inaccurate recorded data.

Change-Id: I12410383f643f37bd32781697167586b990b39e2
Bug: 1441221
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4742190


Reviewed-by: default avatarKelvin Jiang <kelvinjiang@chromium.org>
Commit-Queue: Justin Lulejian <jlulejian@chromium.org>
Auto-Submit: Justin Lulejian <jlulejian@chromium.org>
Reviewed-by: default avatarDevlin Cronin <rdevlin.cronin@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1180609}
parent e0847af4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment