tags:

views:

33

answers:

1

Is qx.io.remote.RPC muti threaded? or it will be a grief to use same object to call multiple services and methods with same object? like:

var myRpc = new qx.io.remote.RPC(url, service1);

var handler1 = function(..){...};
myRpc.callAsync(handler1, method1);

var handler2 = function(..){...};
myRpc.callAsync(handler2, method2);

var result = myRpc.callSync(method3);

or I should create a new object for each of the calls?

+3  A: 

Hi,

whenever you use the "callAsync" or "callSync" method a unique request is created internally. So you can create one RPC instance and perform multiple calls with this instance.

The only delimiter is the internal queue of the browsers. This handled by qooxdoo (the max number of request is checked) and the fallback is 2.

Alexander Steitz