Home Help Center

fast response of a twoway after a huge batch

DavidDavid Member
I have a lot of oneway invocation and some twoway invocation.
If I invoke 1000 oneways in one batch (each operation takes 100ms) and immediately after the batch flushing I invoke a twoway operation. The response for the twoway takes several seconds instead of few ms, because the batch is processed first.

I tryed to run 2 endpoints, one on port 10000 for the oneway invocations and one on port 1005 for the twoway operation. Even with 2 endpoints the behavier is the same like with one endpoint.

Any ideas how to solve my problem?



  • matthewmatthew NL, CanadaMember Matthew NewhookOrganization: ZeroC, Inc.Project: Internet Communications Engine ✭✭✭
    How many threads are in the thread pool on the server side when you used multiple endpoints? By default this size is one, and the thread pool is shared by the two endpoints. Therefore only one request can be dispatched at one time by the pool. I recommend reading the Ice manual for more information.
  • marcmarc FloridaAdministrators, ZeroC Staff Marc LaukienOrganization: ZeroC, Inc.Project: The Internet Communications Engine ZeroC Staff
    As Matthew says, you need at least two threads in the server side thread pool. All requests from a batch are serialized, which means that if you have only one thread, your server will first process the 1000 batch requests before it can process the twoway request. The number of endpoints doesn't matter as they share the thread pool (except if you use different endpoints for different object adapters, and configure each of these adapters to have their own thread pools).
Sign In or Register to comment.