Bug 53241 - ResourceLoadScheduler::scheduleSubresourceLoad() should use ResourceRequest priority
Summary: ResourceLoadScheduler::scheduleSubresourceLoad() should use ResourceRequest p...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Page Loading (show other bugs)
Version: 528+ (Nightly build)
Hardware: Mac OS X 10.6
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on: 53192
Blocks:
  Show dependency treegraph
 
Reported: 2011-01-27 08:32 PST by David Kilzer (:ddkilzer)
Modified: 2011-02-02 12:27 PST (History)
4 users (show)

See Also:


Attachments
Experimental patch (4.55 KB, patch)
2011-01-27 08:38 PST, David Kilzer (:ddkilzer)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Kilzer (:ddkilzer) 2011-01-27 08:32:54 PST
After changes for Bug 53192, ResourceLoadScheduler::scheduleSubresourceLoad() should be able to use the priority on the ResourceRequest object instead of passing it in as a separate argument.
Comment 1 David Kilzer (:ddkilzer) 2011-01-27 08:38:12 PST
Created attachment 80334 [details]
Experimental patch

NOTE: When this patch is applied to a Snow Leopard system (which doesn't use HTTP pipelining), a single test fails:

    LayoutTests/http/tests/xmlhttprequest/logout.html

Running the layout test in Safari 5.0.3 (with a recent WebKit but without the patch applied), these URLs are loaded and the test PASSES:

127.0.0.1 - - [24/Jan/2011:15:45:46 -0800] "GET /xmlhttprequest/logout.html HTTP/1.1" 200 2083
127.0.0.1 - - [24/Jan/2011:15:45:46 -0800] "GET /xmlhttprequest/resources/logout/resource.php?login HTTP/1.1" 401 23
127.0.0.1 - user [24/Jan/2011:15:45:46 -0800] "GET /xmlhttprequest/resources/logout/resource.php?login HTTP/1.1" 200 27
127.0.0.1 - user [24/Jan/2011:15:45:46 -0800] "GET /xmlhttprequest/resources/logout/resource.php?isAuthenticated HTTP/1.1" 200 27
127.0.0.1 - logout [24/Jan/2011:15:45:46 -0800] "GET /xmlhttprequest/resources/logout/resource.php?isAuthenticated HTTP/1.1" 401 23
127.0.0.1 - logout [24/Jan/2011:15:45:46 -0800] "GET /xmlhttprequest/resources/logout/resource.php?isAuthenticated HTTP/1.1" 401 23
127.0.0.1 - user [24/Jan/2011:15:45:46 -0800] "GET /xmlhttprequest/resources/logout/resource.php?isAuthenticated HTTP/1.1" 200 27
127.0.0.1 - - [24/Jan/2011:15:45:46 -0800] "GET /favicon.ico HTTP/1.1" 200 1150

After applying the patch and running Safari 5.0.3 with the new WebKit, these URLs are loaded and the test FAILS:

127.0.0.1 - - [24/Jan/2011:15:45:50 -0800] "GET /xmlhttprequest/logout.html HTTP/1.1" 200 2083
127.0.0.1 - - [24/Jan/2011:15:45:50 -0800] "GET /xmlhttprequest/resources/logout/resource.php?login HTTP/1.1" 401 23
127.0.0.1 - user [24/Jan/2011:15:45:51 -0800] "GET /xmlhttprequest/resources/logout/resource.php?login HTTP/1.1" 200 27
127.0.0.1 - user [24/Jan/2011:15:45:51 -0800] "GET /xmlhttprequest/resources/logout/resource.php?isAuthenticated HTTP/1.1" 200 27
127.0.0.1 - user [24/Jan/2011:15:45:51 -0800] "GET /xmlhttprequest/resources/logout/resource.php?isAuthenticated HTTP/1.1" 200 27
127.0.0.1 - user [24/Jan/2011:15:45:51 -0800] "GET /xmlhttprequest/resources/logout/resource.php?isAuthenticated HTTP/1.1" 200 27
127.0.0.1 - - [24/Jan/2011:15:45:51 -0800] "GET /favicon.ico HTTP/1.1" 200 1150

There seems to be a dependency on the separate priority passed through ResourceLoadScheduler::scheduleSubresourceLoad().
Comment 2 Alexey Proskuryakov 2011-01-27 09:05:34 PST
It's not necessarily obvious if ResourceLoader priorities are conceptually the same as HTTP priorities. Perhaps these should stay separate, and use separate enums.