Bug 164558

Summary: Block synchronous loads for resources that use HTTP 0.9 protocol
Product: WebKit Reporter: Daniel Bates <dbates>
Component: WebCore Misc.Assignee: Daniel Bates <dbates>
Status: RESOLVED INVALID    
Severity: Normal CC: achristensen, aestes, ap, beidson, bfulgham, buildbot, cdumez, commit-queue, japhet, mkwst, rniwa, wilander, youennf
Priority: P2    
Version: WebKit Local Build   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch and layout tests
none
Archive of layout-test-results from ews101 for mac-yosemite
none
Archive of layout-test-results from ews107 for mac-yosemite-wk2
none
Archive of layout-test-results from ews121 for ios-simulator-wk2
none
Patch and layout test none

Description Daniel Bates 2016-11-09 12:46:19 PST
We should block synchronous loads for resources that use the HTTP 0.9 protocol.
Comment 1 Daniel Bates 2016-11-09 12:47:38 PST
Created attachment 294268 [details]
Patch and layout tests
Comment 2 Build Bot 2016-11-09 13:45:28 PST
Comment on attachment 294268 [details]
Patch and layout tests

Attachment 294268 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.webkit.org/results/2485095

New failing tests:
http/tests/security/http-0.9/xhr-blocked.html
Comment 3 Build Bot 2016-11-09 13:45:33 PST
Created attachment 294281 [details]
Archive of layout-test-results from ews101 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews101  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 4 Build Bot 2016-11-09 13:51:30 PST
Comment on attachment 294268 [details]
Patch and layout tests

Attachment 294268 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.webkit.org/results/2485120

New failing tests:
http/tests/security/http-0.9/xhr-blocked.html
Comment 5 Build Bot 2016-11-09 13:51:34 PST
Created attachment 294282 [details]
Archive of layout-test-results from ews107 for mac-yosemite-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews107  Port: mac-yosemite-wk2  Platform: Mac OS X 10.10.5
Comment 6 Build Bot 2016-11-09 14:01:51 PST
Comment on attachment 294268 [details]
Patch and layout tests

Attachment 294268 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: http://webkit-queues.webkit.org/results/2485130

New failing tests:
http/tests/security/http-0.9/xhr-blocked.html
Comment 7 Build Bot 2016-11-09 14:01:55 PST
Created attachment 294285 [details]
Archive of layout-test-results from ews121 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews121  Port: ios-simulator-wk2  Platform: Mac OS X 10.11.6
Comment 8 Daniel Bates 2016-11-09 14:15:47 PST
Created attachment 294288 [details]
Patch and layout test
Comment 9 Brent Fulgham 2016-11-09 14:46:23 PST
Comment on attachment 294288 [details]
Patch and layout test

Looks good. r=me.
Comment 10 Brady Eidson 2016-11-09 15:55:27 PST
This patch seems wrong.

It waits for the sync response to come back from the loading process, which means that the load actually took place.

i.e., it could be a 10mb file that takes ~60 seconds to load, and we'd load it, and block the web process for a minute, then throw it all away.

Instead, why can't we decide that it's http 0.9 *right at response time* and kill the load then?
Comment 11 Daniel Bates 2016-11-09 16:15:15 PST
(In reply to comment #10)
> This patch seems wrong.
> 
> It waits for the sync response to come back from the loading process, which
> means that the load actually took place.
> 

You're right!

> i.e., it could be a 10mb file that takes ~60 seconds to load, and we'd load
> it, and block the web process for a minute, then throw it all away.
> 
> Instead, why can't we decide that it's http 0.9 *right at response time* and
> kill the load then?

Will update patch to do this.
Comment 12 Daniel Bates 2016-11-11 12:15:26 PST
Comment on attachment 294288 [details]
Patch and layout test

This patch is not necessary. We need to move the HTTP 0.9 blocking machinery to ResourceHandle/NetworkLoad to ensure that the machinery applies to all loads.