ActiveMQ
  1. ActiveMQ
  2. AMQ-1818

transport deadlock attempting to shutdown the broker

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 5.1.0
    • Fix Version/s: 5.2.0
    • Component/s: Transport
    • Labels:
      None
    • Environment:

      Red Hat Desktop release 4 (Nahant Update 4)
      Linux ecbuild-lin1 2.6.9-42.ELsmp #1 SMP Wed Jul 12 23:27:17 EDT 2006 i686 i686 i386 GNU/Linux
      ActiveMQ 5.1.0

      Description

      While attempting to shutdown a JVM with an embedded broker listening on a stomp+ssl port, I ran into the following deadlock:

      Found one Java-level deadlock:
      =============================
      "ActiveMQ Transport: ssl:///127.0.0.1:43713":
        waiting to lock monitor 0x8d587f70 (object 0x9b8362b0, a java.lang.Object),
        which is held by "BrokerService"
      "BrokerService":
        waiting to lock monitor 0x08901314 (object 0x9b8527b0, a java.lang.Object),
        which is held by "ActiveMQ Transport: ssl:///127.0.0.1:43713"
      
      Java stack information for the threads listed above:
      ===================================================
      "ActiveMQ Transport: ssl:///127.0.0.1:43713":
      	at org.apache.activemq.transport.MutexTransport.oneway(MutexTransport.java:40)
      	- waiting to lock <0x9b8362b0> (a java.lang.Object)
      	at org.apache.activemq.broker.TransportConnection.dispatch(TransportConnection.java:1188)
      	at org.apache.activemq.broker.TransportConnection.processDispatch(TransportConnection.java:776)
      	at org.apache.activemq.broker.TransportConnection.dispatchSync(TransportConnection.java:735)
      	at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:182)
      	at org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:68)
      	at org.apache.activemq.transport.InactivityMonitor.onCommand(InactivityMonitor.java:206)
      	- locked <0x9b852bb0> (a org.apache.activemq.transport.InactivityMonitor$1)
      	at org.apache.activemq.transport.stomp.StompTransportFilter.sendToActiveMQ(StompTransportFilter.java:80)
      	- locked <0x9b8527b0> (a java.lang.Object)
      	at org.apache.activemq.transport.stomp.ProtocolConverter.sendToActiveMQ(ProtocolConverter.java:134)
      	at org.apache.activemq.transport.stomp.ProtocolConverter.onStompUnsubscribe(ProtocolConverter.java:424)
      	at org.apache.activemq.transport.stomp.ProtocolConverter.onStompCommad(ProtocolConverter.java:184)
      	at org.apache.activemq.transport.stomp.StompTransportFilter.onCommand(StompTransportFilter.java:70)
      	at org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:84)
      	at org.apache.activemq.transport.tcp.SslTransport.doConsume(SslTransport.java:104)
      	at org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:196)
      	at org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:183)
      	at java.lang.Thread.run(Thread.java:619)
      "BrokerService":
      	at org.apache.activemq.transport.stomp.StompTransportFilter.sendToActiveMQ(StompTransportFilter.java:80)
      	- waiting to lock <0x9b8527b0> (a java.lang.Object)
      	at org.apache.activemq.transport.stomp.StompSubscription.onMessageDispatch(StompSubscription.java:71)
      	at org.apache.activemq.transport.stomp.ProtocolConverter.onActiveMQCommad(ProtocolConverter.java:550)
      	at org.apache.activemq.transport.stomp.StompTransportFilter.oneway(StompTransportFilter.java:59)
      	at org.apache.activemq.transport.InactivityMonitor.oneway(InactivityMonitor.java:233)
      	- locked <0x9b857d50> (a java.util.concurrent.atomic.AtomicBoolean)
      	at org.apache.activemq.transport.MutexTransport.oneway(MutexTransport.java:40)
      	- locked <0x9b8362b0> (a java.lang.Object)
      	at org.apache.activemq.broker.TransportConnection.dispatch(TransportConnection.java:1188)
      	at org.apache.activemq.broker.TransportConnection.processDispatch(TransportConnection.java:776)
      	at org.apache.activemq.broker.TransportConnection.iterate(TransportConnection.java:813)
      	at org.apache.activemq.thread.PooledTaskRunner.runTask(PooledTaskRunner.java:122)
      	at org.apache.activemq.thread.PooledTaskRunner$1.run(PooledTaskRunner.java:43)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
      	at java.lang.Thread.run(Thread.java:619)
      
      Found 1 deadlock.
      

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Resolved Resolved
        94d 12h 40m 1 Rob Davies 23/Sep/08 07:56
        Jeff Turner made changes -
        Project Import Fri Nov 26 22:32:02 EST 2010 [ 1290828722158 ]
        Gary Tully made changes -
        Fix Version/s 5.3.0 [ 11914 ]
        Fix Version/s 5.2.0 [ 11841 ]
        Rob Davies made changes -
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Hide
        Rob Davies added a comment -

        Fixed by SVN revision 698103

        Show
        Rob Davies added a comment - Fixed by SVN revision 698103
        Rob Davies made changes -
        Assignee Rob Davies [ rajdavies ]
        Rob Davies made changes -
        Field Original Value New Value
        Fix Version/s 5.3.0 [ 11914 ]
        Hide
        Augusto Rodriguez added a comment -

        Scott,

        I ran in the same problem and it looks like this might be solved in AMQ-1819 (version 5.2.0)

        Cheers,
        Augusto

        Show
        Augusto Rodriguez added a comment - Scott, I ran in the same problem and it looks like this might be solved in AMQ-1819 (version 5.2.0) Cheers, Augusto
        Scott Stanton created issue -

          People

          • Assignee:
            Rob Davies
            Reporter:
            Scott Stanton
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development