ASSIGNED 79773
cached resources are not reused when there are no cache headers present
https://bugs.webkit.org/show_bug.cgi?id=79773
Summary cached resources are not reused when there are no cache headers present
Lea Verou
Reported 2012-02-28 03:04:04 PST
Hover over the image in the testcase. You will see that the second image loads again, although it had already been loaded for cross-fade() to work. This is wasteful and should be rectified.
Attachments
reduced test case (508 bytes, text/html)
2012-04-13 07:19 PDT, Shezan Baig
no flags
Patch (4.49 KB, patch)
2012-04-13 10:17 PDT, Shezan Baig
ap: review-
webkit.review.bot: commit-queue-
Archive of layout-test-results from ec2-cr-linux-01 (6.76 MB, application/zip)
2012-04-13 12:19 PDT, WebKit Review Bot
no flags
Radar WebKit Bug Importer
Comment 1 2012-02-28 09:20:56 PST
Shezan Baig
Comment 2 2012-04-13 07:19:58 PDT
Created attachment 137083 [details] reduced test case reduced test case by removing cross-fade (which appears to no longer work in firefox, btw). We load 2 images, and when mouse hover on the first image, we change it to the second image. In firefox, this change is instantaneous, but in webkit, this change reloads the image. the issue has nothing to do with cross-fade itself, but has to do with the fact that cached resources is not reused when there are no cache headers present. Specifically, CachedResource::freshnessLifetime currently returns 0. The comment says that other browsers do this, but it seems like firefox doesn't. I plan to fix this by bumping it up from 0 to 3600 (i.e. 1 hour). I'm open to alternate suggestions though.
Simon Fraser (smfr)
Comment 3 2012-04-13 08:36:20 PDT
Please re-title this bug to reflect the actual issue.
Shezan Baig
Comment 4 2012-04-13 10:17:21 PDT
Created attachment 137100 [details] Patch returning 3600 in freshnessLifetime if no cache headers present
Alexey Proskuryakov
Comment 5 2012-04-13 10:29:04 PDT
Antti should review this.
Antti Koivisto
Comment 6 2012-04-13 10:36:24 PDT
What is the current behavior in other engines? It seems bit risky to change this if everyone else considers these resources uncacheable.
Antti Koivisto
Comment 7 2012-04-13 10:52:14 PDT
Ah you mentioned Firefox. Wonder what their exact behavior is?
Shezan Baig
Comment 8 2012-04-13 11:31:37 PDT
I'm not sure what their exact behavior is, i'll investigate this further
WebKit Review Bot
Comment 9 2012-04-13 12:19:12 PDT
Comment on attachment 137100 [details] Patch Attachment 137100 [details] did not pass chromium-ews (chromium-xvfb): Output: http://queues.webkit.org/results/12405044 New failing tests: http/tests/misc/script-async.html http/tests/xmlhttprequest/access-control-basic-allow-preflight-cache.html
WebKit Review Bot
Comment 10 2012-04-13 12:19:19 PDT
Created attachment 137123 [details] Archive of layout-test-results from ec2-cr-linux-01 The attached test failures were seen while running run-webkit-tests on the chromium-ews. Bot: ec2-cr-linux-01 Port: <class 'webkitpy.common.config.ports.ChromiumXVFBPort'> Platform: Linux-2.6.35-28-virtual-x86_64-with-Ubuntu-10.10-maverick
Ryosuke Niwa
Comment 11 2012-05-10 00:56:39 PDT
This is definitely not a CSS bug.
Alexey Proskuryakov
Comment 12 2012-05-10 11:00:35 PDT
Comment on attachment 137100 [details] Patch This change needs supportive evidence. Please feel free to ask for review again with evidence provided.
Note You need to log in before you can comment on or make changes to this bug.