[wp-trac] [WordPress Trac] #17238: Parallel HTTP Requests
WordPress Trac
wp-trac at lists.automattic.com
Tue Mar 13 21:46:55 UTC 2012
#17238: Parallel HTTP Requests
-----------------------------+-----------------------------
Reporter: sterlo | Owner:
Type: feature request | Status: reopened
Priority: normal | Milestone: Future Release
Component: HTTP | Version:
Severity: normal | Resolution:
Keywords: |
-----------------------------+-----------------------------
Changes (by kurtpayne):
* cc: kpayne@… (added)
Comment:
Replying to [comment:7 sterlo]:
> Replying to [comment:6 dd32]:
> > non-blocking requests allow the request to be made, however no output
from the server is captured.
>
> Yes. But with ajax this can be done with ease.
If you mean "use ajax for parallel requests" then that introduces new
problems. Ajax has a security model that restricts requests to the same
domain only.
If you mean "use ajax and proxy connections through wordpress' WP_HTTP
classes" then that would only work when then action was initiated from a
browser. Actions initiated from crons would not have access to this.
These requests would also compete with other ajax requests in the browser.
There is a maximum number of simultaneous ajax requests, too, that differs
per browser (I believe the average right now is 8).
As you've pointed out, curl+php does support this with curl_multi_*
functions http://us.php.net/manual/en/function.curl-multi-init.php
I agree that this would be cool to have, but it's not something that is
supported by all of the WP_HTTP implementations (as dd32 said). I don't
think this can be done properly.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/17238#comment:10>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list