Q'ing of inbound requests

How does RO queue inbound requests, and how many requests can it handle at once assuming we are using the default class factory? We tried doing some simple tests to overload the server with client requests but it seemed to queue them just fine. Further analysis seemed to show that our service methods would get hit in batches of 6 and this was increased to 12 when we used virtual machines with more cores. How we tested: we created a RO server with a service method that basically logged the start and end and slept for 10 seconds in between before it returned. On the client side we established a session and called this method 200 times.

How does this actually work internally, s is RO queuing the requests before passing on to service methods?

Thanks Bob

1 Like

Hello

What is you server platform (ie it is .NET or Delphi)?

We are using Delphi. Thanks

For default class factory, service instance is created for each request in personal thread so if 100 simultaneous requests were sent, 100 threads will be created in server-side.

Using the default class factory is there a limit as to how many threads are created? I thought I read in a forum post there were 5 pools of 10 threads?

If there is a limit, what happens when it’s reached, will the server send an error back to the client?

ASP.net has a feature called Async/Await which allows threads to be released when requests require longer processing time. Does something similar exist in RO? I found this link on asp.net which describes Async/Await Async Programming - Introduction to Async/Await on ASP.NET | Microsoft Learn

Thanks Bob

1 Like

default class factory hasn’t limitation, but you can use any other class factories.

of course we support asynchronous calls. you can use _Async and _AsyncEx versions of interfaces of your services.

example of usage in the Async and Phone Photo Server samples

So if I understand your documentation correctly, (found at the link below), Async is handled entirely on the client side? Thus a worker thread is started on the Delphi client side which waits for the service call to finish? thanks Bob

http://old.wiki.remobjects.com/wiki/Asynchronous_Calls_in_RemObjects_SDK_(Delphi)

Yep, you are right.
Asynchronous calls are called in background thread on client-side.
Server-side doesn’t distinguish clients calls (usual or async) and process every request as usual call.

of course, you can create your own infrastructure when each request will be put into queue on server-side with different priorities and executed according to these priorities but usually this can be needed only for very specific cases

1 Like