activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Timothy Bish (Closed) (JIRA)" <>
Subject [jira] [Closed] (AMQ-1447) Broker cannot shutdown cleanly due to hanging non-daemon threads.
Date Tue, 04 Oct 2011 23:35:34 GMT


Timothy Bish closed AMQ-1447.

       Resolution: Fixed
    Fix Version/s:     (was: 5.3.0)

Workaround exists, add daemon=true to the URI as commented in the issue.
> Broker cannot shutdown cleanly due to hanging non-daemon threads.
> -----------------------------------------------------------------
>                 Key: AMQ-1447
>                 URL:
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.1.1
>         Environment: Windows XP, JDK 1.4.2
>            Reporter: William Lam
>             Fix For: 5.4.2
> Running with an embedded broker inside an application, the application failed to shutdown
cleanly due to some hanging ActiveMQ non-daemon threads, sample stacktace as below.
> "ActiveMQ Transport: tcp://oat-dualcore113/" prio=5 tid=0x041b8658
nid=0x12f4 in Object.wait() [6c7f000..6c7fdc0]
> 	at java.lang.Object.wait(Native Method)
> 	- waiting on <0x168c0490> (a
> 	at java.lang.Object.wait(
> 	at
> 	- locked <0x168c0490> (a
> 	at
> 	at
> 	at$2.onCommand(
> 	at org.apache.activemq.transport.ResponseCorrelator.onCommand(
> 	at org.apache.activemq.transport.TransportFilter.onCommand(
> 	at org.apache.activemq.transport.WireFormatNegotiator.onCommand(
> 	at org.apache.activemq.transport.InactivityMonitor.onCommand(
> 	at org.apache.activemq.transport.TransportSupport.doConsume(
> 	at
> 	at
> It may be caused by other invalid broker connection attempts (not sure how) and TcpTransport
is waiting for a successful connection to the remote broker.  
> Various ways to workaround that failed,
> - TcpTransport is not being exposed to the application by any means (unlike ActiveMQConnection
- even though it is package not public)
> - no means to set the TcpTransport as daemon since it is set on the constructor
> Have to put in some 'custom' code in the application to find all 'ActiveMQ' non-daemon
threads and stop() them.  Note interrupt() won't work since InterruptedException was ignored.
> I am using the default multicast for broker discovery  (tried that with other multicast
address, same problem)
>     <networkConnectors>
>       <networkConnector name="default" uri="multicast://default" failover="false"/>
>     </networkConnectors>

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message