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

Issue 1893233002: WebFonts: reset m_loadLimitState on memory cache revalidation (Closed)

Created:
4 years, 8 months ago by Takashi Toyoshima
Modified:
4 years, 8 months ago
CC:
chromium-reviews, blink-reviews, loading-reviews+fetch_chromium.org, tyoshino+watch_chromium.org, Nate Chapin, gavinp+loader_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

WebFonts: reset m_loadLimitState on memory cache revalidation On reload, RevalidationPolicy Revalidate is applied. This policy reuses the same Resource instance for the reloading Resource, and FontResource::startLoadLimitTimersIfNeeded() is called again. FontResource does not expect that startLoadLimitTimersIfNeeded() is called twice, and needs a place to reset an internal state to manage font loading timeouts. This patch changes Resource::setRevalidatingRequest to virtual and reset m_loadLimitState at FontResource::setRevalidatingRequest. BUG=603392 Committed: https://crrev.com/27d8b39e91bfc8ffd53c27cfb8dee3029b122d24 Cr-Commit-Position: refs/heads/master@{#389359}

Patch Set 1 #

Patch Set 2 : . #

Patch Set 3 : ASSERT wasn't correct #

Patch Set 4 : add a LayoutTest #

Total comments: 2

Patch Set 5 : address hiroshige's comments at #11 #

Total comments: 6

Patch Set 6 : #14 #

Messages

Total messages: 28 (11 generated)
Takashi Toyoshima
Can you take a look?
4 years, 8 months ago (2016-04-18 05:57:36 UTC) #3
tyoshino (SeeGerritForStatus)
Description/subject: WebFotns -> WebFonts
4 years, 8 months ago (2016-04-18 12:05:59 UTC) #6
Takashi Toyoshima
Done for #6. After #3, I had a offline chat with ksakamoto and hiroshige, and ...
4 years, 8 months ago (2016-04-18 12:13:04 UTC) #8
Takashi Toyoshima
hiroshige: what do you think about this Resource related code change?
4 years, 8 months ago (2016-04-18 15:43:33 UTC) #9
Takashi Toyoshima
ksakamoto: I added a layout test we talked in Patch Set 4. PTAL.
4 years, 8 months ago (2016-04-19 07:38:20 UTC) #10
hiroshige
Basically looks good. https://codereview.chromium.org/1893233002/diff/60001/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp File third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp (right): https://codereview.chromium.org/1893233002/diff/60001/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp#newcode545 third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp:545: resource->prepareToRevalidate(); How about calling prepareToRevalidate() in ...
4 years, 8 months ago (2016-04-19 07:51:50 UTC) #11
Kunihiko Sakamoto
FontResource change and test lgtm
4 years, 8 months ago (2016-04-19 07:55:36 UTC) #12
Takashi Toyoshima
PTAL https://codereview.chromium.org/1893233002/diff/60001/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp File third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp (right): https://codereview.chromium.org/1893233002/diff/60001/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp#newcode545 third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp:545: resource->prepareToRevalidate(); Thanks, that sounds smart, and I can ...
4 years, 8 months ago (2016-04-19 08:39:01 UTC) #13
hiroshige
https://codereview.chromium.org/1893233002/diff/80001/third_party/WebKit/LayoutTests/http/tests/webfont/font-load-revalidation.html File third_party/WebKit/LayoutTests/http/tests/webfont/font-load-revalidation.html (right): https://codereview.chromium.org/1893233002/diff/80001/third_party/WebKit/LayoutTests/http/tests/webfont/font-load-revalidation.html#newcode9 third_party/WebKit/LayoutTests/http/tests/webfont/font-load-revalidation.html:9: testRunner.waitUntilDone(); We can write |jsTestIsAsync = true;| instead of ...
4 years, 8 months ago (2016-04-21 07:39:11 UTC) #14
Takashi Toyoshima
Thanks, I also update one more test to use jsTestIsAsync in the same directory. Others ...
4 years, 8 months ago (2016-04-21 08:31:25 UTC) #15
hiroshige
non-owner lgtm if bots are happy.
4 years, 8 months ago (2016-04-21 08:39:43 UTC) #16
hiroshige
Please update the CL description: Resource::PrepareToRevalidate() no longer exists in the latest PatchSet.
4 years, 8 months ago (2016-04-21 08:41:08 UTC) #17
Takashi Toyoshima
description was updated to describe the latest patch correctly. +Nate for fetch/loader owner review.
4 years, 8 months ago (2016-04-22 06:05:09 UTC) #20
Nate Chapin
Unfortunate to have to virtual-ize yet another function on Resource, but this makes sense. LGTM
4 years, 8 months ago (2016-04-22 20:56:22 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1893233002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1893233002/100001
4 years, 8 months ago (2016-04-23 01:00:16 UTC) #24
commit-bot: I haz the power
Committed patchset #6 (id:100001)
4 years, 8 months ago (2016-04-23 03:59:31 UTC) #26
commit-bot: I haz the power
4 years, 8 months ago (2016-04-23 04:00:49 UTC) #28
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/27d8b39e91bfc8ffd53c27cfb8dee3029b122d24
Cr-Commit-Position: refs/heads/master@{#389359}

Powered by Google App Engine
This is Rietveld 408576698