[Webkit-unassigned] [Bug 30862] Dynamically inserted subresources aren't revalidated even when the containing document is reloaded

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Feb 3 09:45:32 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=30862





--- Comment #39 from Kyle Simpson <getify at gmail.com>  2011-02-03 09:45:31 PST ---
Forgive my stubborness, but I still do not understand why a shift+refresh should ONLY re-validate some resources (those that came in initial page load) and not others?

I've heard several times in this thread that it simply can't be done without losing an important User-Experience optimization, but I haven't seen a single actual explanation of that techinical limitation.

If a *user* says, "I want to refresh this page because things seem to not be working correctly" (or) "I want to refresh this page because the support forums/representatives of the site told me to", in what use-case(s) are we saying that this use would actually only want some of the resources on that page re-validated, and not others?

BOTTOM LINE: How on earth can the browser justify doing something which doesn't make sense to an end-user? If an end-user clicks refresh, or does shift+refresh even, they are almost certainly saying "refresh everything", not expecting you to only refresh some things and not others. How does the current behavior not violate the principle of lease-surprise???

----------------
That question aside, for a moment...

I'm quite confused by the alternate suggestion. How is a dynamic script loader (like mine, LABjs), supposed to:

1. detect that a "refresh" of a page-view is happening; AND
2. somehow manually force all the resources I'm going to ask for to be re-validated

Adding a ?x=128945839853 type cache-buster to all the URLs is not what we want, because we don't want a full reload, we want the browser to re-validate (an If-Modified-Since request).

As it stands now, any resources which were sent with a "Last-Modified" response header will be re-validated, but ONLY so long as that resource arrived during/before initial page load. If a resource is sent with "Last-Modified" in response to a dynamic resource load after initial page-load, essentially the browser will ignore this header, because it will not re-validate the next time that resource is requested in the same manner.

Are we suggesting that every resource container expose some property that indicates whether or not the resource it contains is subject to re-validation or not? Because I'd of course only want to force my own re-validation on resources in which the browser wouldn't already be inclined to re-validate.

Also, keep in mind there are various ways that resources are loaded, from XHR to dynamic script/link tags, to iframes, <object>s, <img>s, etc. If the suggestion is that we create a mechanism by which a web author (ie, me, as a script loader author) can force a re-validation, it has to take into account all those possible request methods.

Perhaps a `rel` attribute can be added to a resource request that is like `rel="alwaysRevalidate"` or something like that?

It sure sounds like we're going down a MUCH more complicated path than something like the "super-refresh" idea. And I completely don't understand why there'd need to be a timeout on it.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list