Search |
||
Configuring Thread pool(s) in SailFinPosted by rampsarathy on June 27, 2008 at 8:22 AM PDT
SailFin SIP container requires threads to do various tasks like process an incoming request, send a response, execute timers and initiate new requests with clients. The threads required to perform these tasks are obtained from thread pools which are specifically created and configured for the sip-service in SailFin. In other words, the worker threads used in SailFin SIP container are not obtained from the legacy ORB thread pool, which a typical container inside Glassfish would do. Here is my understanding of what these thread pools are and how they can be configured, so that one can obtain the optimum performance out of the system. The configuration is present in domain.XML and can be modified through asadmin set commands or the administration GUI. <sip-service> <request-processing initial-thread-count="10" initial-thread-count specifies how many threads are loaded in the pool when the pool initializes, thread-count denotes the maximum threads in the thread-pool and thread-increment will allow a user to configure the number of threads by which the pool will be expanded when there are more threads required and the number of threads in the pool is less than the thread-count. If a user feels that 2 separate pools (pipelines) are not required and one single pipeline can be shared for the client and server tasks then that can be accomplished by setting this system property The maximum number of requests that can be queued in the thread pool (pipeline) can be configured through the following property in domain.XML <connection-pool queue-size-in-bytes="-1" A value of -1 indicates the queue is unbounded. The ServersThreadPool threads can be identified in the server.log using the name "SipContainer-serversWorkerThread-5060-0" where 5060 is the listener port. The ClientThreadPool threads can be identified by the name "SipContainer-clientsWorkerThread-5060-0" All the listeners (5060, 5061....) in the SIP container share the ServersThreadPool and ClientsThreadPool, it is per container and not per-listener. In other words, there is no partiality in executing work whether it comes from 5060, 5061 or any other sip listener, its FCFS. SipContainerThreadPool : The implementation of this is within sailfin and each thread is a SipContainerThreadPoolThread. It is capable of queuing and executing Callable tasks on the free threads available in the pool. But the number of tasks that can be queued is unbounded (and cannot be configured) so there is no way to control/throttle the request processing in this thread pool. As of today, it shares configuration with the ServersThreadPool and ClientsThreadPool for the maximum and initial thread count values. Please follow Issue 915 for updates on this. »
Related Topics >>
J2EE Comments
Comments are listed in date ascending order (oldest first)
Submitted by tapask1 on Sun, 2008-07-27 23:18.
Its a nice Post ramesh,
I was searching for something HTTP pipelining i just got it
can you help me regarding HTTP Pipelinging,Like it should Submit a number of pipelined HTTP GETs to maintain a pool ready to be responded to when there is a message to be sent to the client.
i can share the code if u want.....
Thanks & Regards,
Submitted by rampsarathy on Sun, 2008-07-27 23:26.
your question about http pipelining might be relevant in the Grizzly forums/groups, please post it there (users@grizzly.dev.java.net)
Submitted by binod on Fri, 2008-06-27 08:50.
Nice post, Ramesh..
Is there a reason why one system property starts with "sip.network.grizzly" and another with "org.jvnet.glassfish.comms" ?
|
||
|
|