Introduction to the Java RPC Server

The EntireX Java RPC Server allows standard RPC clients to communicate with servers written in Java. It works together with the Java Wrapper and calls Java server interface objects.


Worker Models

graphics/intro_workerModels-java.png

RPC requests are worked off inside the RPC server in worker threads. Every RPC request occupies during its processing a worker thread. If you are using RPC conversations, each RPC conversation requires its own thread during the lifetime of the conversation. The Java RPC Server can adjust the number of worker threads to the number of parallel requests. Use the properties entirex.server.fixedservers, entirex.server.maxservers and entirex.server.minservers to configure this scalability. The Java RPC Server provides two worker models:

  • FIXED
  • The fixed model creates a fixed number of worker threads. If entirex.server.fixedservers=yes, the number of worker threads is specified in entirex.server.minservers is started and the server can process this number of parallel requests.

  • SCALE
    The scale model creates worker threads depending on the incoming load of RPC requests. If entirex.server.fixedservers=no, the number of worker threads balances between what is specified in entirex.server.minservers and what is specified in entirex.server.maxservers. This is done by a so-called attach thread. At startup, the number of worker threads is the number specified in entirex.server.minservers. A new worker thread starts if the broker has more requests than there are worker threads waiting. If more than the number specified in entirex.server.minservers are waiting for requests, a worker thread stops if its receive call times out. The timeout period is configured with entirex.server.waitserver.