|
The Yar_Concurrent_Client classIntroductionA static helper that batches remote RPC calls. Calls registered with Yar_Concurrent_Client::call are not sent immediately; they are all dispatched together, in parallel, by Yar_Concurrent_Client::loop. The class is meant for applications that need the results of several remote calls. Only independent calls — ones that do not need each other's results — can be batched this way; when one call depends on the result of another, the two have to run sequentially. Through Yar_Client the calls are sent one after another, each paying its full round-trip time; with the concurrent client they are sent at the same time, so the overall waiting time drops to the duration of the single slowest call.
Class synopsis
Yar_Concurrent_Client
/* Methods */
public static intfalsenull call(
string $uri,string $method,arraynull $parameters = null,callablenull $callback = null,callablenull $error_callback = null,arraynull $options = null) public static boolnull loop(callablenull
$callback = null, callablenull $error_callback = null, arraynull $options = null)public static bool reset()
|