New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 633743 link

Starred by 4 users

Issue metadata

Status: Fixed
Owner:
Closed: Nov 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 1
Type: Feature

Blocked on:
issue 649166



Sign in to add a comment

Implement watch time metrics for Chrome HTML5 media playback.

Project Member Reported by dalecur...@chromium.org, Aug 2 2016

Issue description

Implement metrics to monitor watch time across Chrome media playback per:

https://docs.google.com/document/d/19mP_EVPkHkzN22QObhL0GYUMzyCAJDpRw3v8Mn3wf5s/preview

Essentially: Watch time for our purposes is defined as the amount of elapsed media time for audio+video media. A minimum of 7 seconds of unmuted, foreground media must be watched to start watch time monitoring. Watch time is checked every 5 seconds from then on and reported to multiple buckets: All, MSE, SRC, EME, AC, and battery.

Any one of paused, hidden, or muted is sufficient to stop watch time metric reports. Each of these has a hysteresis where if the state change is undone within 5 seconds, the watch time will be counted as uninterrupted.

Power events (on/off battery power) have a similar hysteresis, but unlike the aforementioned properties, will not stop metric collection.

Each seek event will result in a new watch time metric being started and the old metric finalized as accurately as possible.

 
Status: Started (was: Assigned)
https://codereview.chromium.org/2160963002
Project Member

Comment 2 by bugdroid1@chromium.org, Aug 17 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/04bdb589651d194444ed3844a5495e432c0f6b3d

commit 04bdb589651d194444ed3844a5495e432c0f6b3d
Author: dalecurtis <dalecurtis@chromium.org>
Date: Wed Aug 17 22:15:23 2016

Add watch time metrics for HTML5 media playback.

Watch time for our purposes is defined as the amount of elapsed media time
for audio+video media. A minimum of 7 seconds of unmuted, foreground media
must be watched to start watch time monitoring. Watch time is checked every
5 seconds from then on and reported to multiple buckets: All, MSE, SRC, EME,
AC, and battery.

Any one of paused, hidden, or muted is sufficient to stop watch time metric
reports. Each of these has a hysteresis where if the state change is undone
within 5 seconds, the watch time will be counted as uninterrupted.

Power events (on/off battery power) have a similar hysteresis, but unlike
the aforementioned properties, will not stop metric collection.

Each seek event will result in a new watch time metric being started and the
old metric finalized as accurately as possible.

BUG= 633743 
TEST=new unittest.

Review-Url: https://codereview.chromium.org/2160963002
Cr-Commit-Position: refs/heads/master@{#412664}

[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/content/browser/media/media_internals.cc
[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/base/media_log.cc
[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/base/media_log.h
[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/base/media_log_event.h
[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/blink/BUILD.gn
[add] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/blink/watch_time_reporter.cc
[add] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/blink/watch_time_reporter.h
[add] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/blink/watch_time_reporter_unittest.cc
[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/blink/webmediaplayer_impl.cc
[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/media/blink/webmediaplayer_impl.h
[modify] https://crrev.com/04bdb589651d194444ed3844a5495e432c0f6b3d/tools/metrics/histograms/histograms.xml

Project Member

Comment 3 by bugdroid1@chromium.org, Aug 19 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/3245392074f030029539d0d65935fb5fdaca1b48

commit 3245392074f030029539d0d65935fb5fdaca1b48
Author: dalecurtis <dalecurtis@chromium.org>
Date: Fri Aug 19 21:13:01 2016

Set units for Media.WatchTime metric.

Forgot to change this in the original CL.

BUG= 633743 

Review-Url: https://codereview.chromium.org/2259303002
Cr-Commit-Position: refs/heads/master@{#413238}

[modify] https://crrev.com/3245392074f030029539d0d65935fb5fdaca1b48/tools/metrics/histograms/histograms.xml

Blockedon: 649166
Labels: Merge-Request-56
Just missed the M56 branch cut, requesting merge.

Comment 7 by dimu@chromium.org, Nov 21 2016

Labels: -Merge-Request-56 Merge-Approved-56 Hotlist-Merge-Approved
Your change meets the bar and is auto-approved for M56 (branch: 2924)
Project Member

Comment 8 by bugdroid1@chromium.org, Nov 21 2016

Labels: -merge-approved-56 merge-merged-2924
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7c02dce64f7c158bee54e9f161bfffd71d45d2dc

commit 7c02dce64f7c158bee54e9f161bfffd71d45d2dc
Author: Dale Curtis <dalecurtis@chromium.org>
Date: Mon Nov 21 20:24:23 2016

Merge M56: "Add audio only watch time metrics."

Enables tracking of audio only "watch time" histograms. They are
the same as the audio+video ones except there is no requirement
on visibility or video size for recording watch time.

BUG= 633743 
TEST=new audio only unittests.

Review-Url: https://codereview.chromium.org/2498113004
Cr-Commit-Position: refs/heads/master@{#433102}
(cherry picked from commit 051d5b8e2973c0f253ade88303b467a043530d23)

Review URL: https://codereview.chromium.org/2517313002 .

Cr-Commit-Position: refs/branch-heads/2924@{#37}
Cr-Branched-From: 3a87aecc31cd1ffe751dd72c04e5a96a1fc8108a-refs/heads/master@{#433059}

[modify] https://crrev.com/7c02dce64f7c158bee54e9f161bfffd71d45d2dc/content/browser/media/media_internals.cc
[modify] https://crrev.com/7c02dce64f7c158bee54e9f161bfffd71d45d2dc/media/base/media_log.cc
[modify] https://crrev.com/7c02dce64f7c158bee54e9f161bfffd71d45d2dc/media/base/media_log.h
[modify] https://crrev.com/7c02dce64f7c158bee54e9f161bfffd71d45d2dc/media/blink/watch_time_reporter.cc
[modify] https://crrev.com/7c02dce64f7c158bee54e9f161bfffd71d45d2dc/media/blink/watch_time_reporter.h
[modify] https://crrev.com/7c02dce64f7c158bee54e9f161bfffd71d45d2dc/media/blink/watch_time_reporter_unittest.cc
[modify] https://crrev.com/7c02dce64f7c158bee54e9f161bfffd71d45d2dc/tools/metrics/histograms/histograms.xml

Status: Fixed (was: Started)

Sign in to add a comment