activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From DominicTulley <>
Subject Re: Tomcat doesn't shutdown when amq client used within webapp
Date Mon, 05 May 2008 14:58:44 GMT

Hi Marco,
thanks for the suggestion.  I think there might be two similar but different
problems.  The jira I raised has been resolved and my immediate problem has
gone away with it.  However, I have seen a report of subscriber/listener
threads not going away on this forum as well and I wonder if your suggestion
is a way to deal with that...


Marco Buss wrote:
> Hello,
> i use a ContextListener. In this Listener i tell every Subscriber that he
> must close his open connection to the Broker. This works for me becaus the
> Subscribers are Singletons in my case.
> MfG
> Marco
> DominicTulley wrote:
>> When we shut down our tomcat server the java process does not terminate
>> and it turns out that the culprit is a couple of threads belonging to the
>> amq client library.
>> The threads are "InactivityMonitor WriteCheck" and "InactivityMonitor
>> ReadCheck".
>> Having had a look at it there seem to be two possibilities.  Either there
>> is some client shutdown method we need to call which will ultimately call
>> InactivityMonitor.stop(), or the two threads should be daemon threads so
>> that they just evaporate.
>> I put in a change to make them daemon threads (trivial change) and tomcat
>> then shuts down correctly.  So, my question is, do we need this change in
>> AMQ or is there some shutdown call I should be making into the libraries? 
>> I am (as far as I can tell!) already closing all the connections we have
>> open.
>> Thanks,
>> -Dominic

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message