Clientside threadpool

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Clientside threadpool

jan_
Hi

I can't get the clientside threadpools, which is intialized by swiftmq, to terminate at all. My JMS client is running under a Resin 2.17 application server, and I really need to get those pools to terminate on WAR-redeploy events to avoid a leak. Same issue occurs if I do testing using some simple JMS accessor code similar to the samples provided with swiftmq. I would assume that closing JMS resources should do the trick, but that does not seem to be the case. Am I missing something here?

Thanks in advance...
Reply | Threaded
Open this post in threaded view
|

Re: Clientside threadpool

IIT Software
Administrator
The threads will die after idle timeout which is 2 minutes. However, the default minimum threads in these pools are 5 so these threads will never die.

Try to set these system properties at resin's command line:

-Dswiftmq.pool.session.threads.min=0
-Dswiftmq.pool.session.idle.timeout=10000
-Dswiftmq.pool.connection.threads.min=0
-Dswiftmq.pool.connection.idle.timeout=10000

It sets the min threads for the session and connection pool to zero and the idle timeout for threads to 10 secs. Therefore, the pools should be empty 10 secs after redeployment of your client.
Reply | Threaded
Open this post in threaded view
|

Re: Clientside threadpool

jan_
That did the trick. Thanks ;-)