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

Issue 23720005: Move webfont usage metrics reporting to FontResource (Closed)

Created:
7 years, 3 months ago by Kunihiko Sakamoto
Modified:
7 years, 3 months ago
Reviewers:
tkent
CC:
blink-reviews, apavlov+blink_chromium.org, dglazkov+blink, eae+blinkwatch, darktears
Visibility:
Public.

Description

Move webfont usage metrics reporting to FontResource CSSFontFaceSource::FontLoadHistograms class reported WebFont.UsageType and WebFont.StyleRecalcToDownloadLatency metrics. But CSSFontFaceSource is destructed/reconstructed when a new @font-face is added to the stylesheet, so these metrics were reported more than once for single webfont when the web page dynamically generates @font-face rules. That caused unexpectedly high "Styled, but not used" count of WebFont.UsageType. To avoid this, this patch moves the reporting code to a inner class of FontResource, and rename the histogram names to WebFont.Resource.*. The metrics are recorded at most once for each FontResource object which is retained by the memory cache. BUG=246492 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=157280

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+55 lines, -34 lines) Patch
M Source/core/css/CSSFontFaceSource.h View 1 chunk +1 line, -9 lines 0 comments Download
M Source/core/css/CSSFontFaceSource.cpp View 1 chunk +2 lines, -25 lines 0 comments Download
M Source/core/fetch/FontResource.h View 2 chunks +17 lines, -0 lines 0 comments Download
M Source/core/fetch/FontResource.cpp View 3 chunks +35 lines, -0 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Kunihiko Sakamoto
Kent-san, could you take a look?
7 years, 3 months ago (2013-09-05 04:42:59 UTC) #1
tkent
lgtm
7 years, 3 months ago (2013-09-05 04:57:08 UTC) #2
Kunihiko Sakamoto
On 2013/09/05 04:57:08, tkent wrote: > lgtm Thanks. I'm going to submit this after getting ...
7 years, 3 months ago (2013-09-05 05:05:22 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ksakamoto@chromium.org/23720005/1
7 years, 3 months ago (2013-09-05 05:39:28 UTC) #4
commit-bot: I haz the power
7 years, 3 months ago (2013-09-05 06:49:41 UTC) #5
Message was sent while issue was closed.
Change committed as 157280

Powered by Google App Engine
This is Rietveld 408576698