You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Gary Tully (JIRA)" <ji...@apache.org> on 2012/08/28 13:38:07 UTC

[jira] [Created] (AMQ-3999) Unsubscribing durable subs can be blocked on calls to determine store size, contending with active subs

Gary Tully created AMQ-3999:
-------------------------------

             Summary: Unsubscribing durable subs can be blocked on calls to determine store size, contending with active subs
                 Key: AMQ-3999
                 URL: https://issues.apache.org/jira/browse/AMQ-3999
             Project: ActiveMQ
          Issue Type: Bug
          Components: Broker
    Affects Versions: 5.6.0
            Reporter: Gary Tully
            Assignee: Gary Tully
             Fix For: 5.7.0



Here is the stack trace showing the thread that is making the call to the getMessageCount when a sub is unsubscribing. This causes unnecessary contention with message addition and can result is pauses. Is it really necessary?

{code}ActiveMQ Transport: tcp:///127.0.0.1:54115
sun.misc.Unsafe.park at line #-2
java.util.concurrent.locks.LockSupport.park at line #186
java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt at line #834
java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireQueued at line #867
java.util.concurrent.locks.AbstractQueuedSynchronizer.acquire at line #1197
java.util.concurrent.locks.ReentrantReadWriteLock$WriteLock.lock at line #945
org.apache.activemq.store.kahadb.KahaDBStore$KahaDBTopicMessageStore.getMessageCount at line #782
org.apache.activemq.store.ProxyTopicMessageStore.getMessageCount at line #116
org.apache.activemq.broker.region.cursors.TopicStorePrefetch.getStoreSize at line #83
org.apache.activemq.broker.region.cursors.AbstractStoreCursor.resetSize at line #66
org.apache.activemq.broker.region.cursors.AbstractStoreCursor.gc at line #246
org.apache.activemq.broker.region.cursors.StoreDurableSubscriberCursor.stop at line #98
org.apache.activemq.broker.region.DurableTopicSubscription.deactivate at line #171
org.apache.activemq.broker.region.TopicRegion.removeConsumer at line #164
org.apache.activemq.broker.region.RegionBroker.removeConsumer at line #473
org.apache.activemq.broker.jmx.ManagedRegionBroker.removeConsumer at line #266
org.apache.activemq.broker.BrokerFilter.removeConsumer at line #117
org.apache.activemq.broker.BrokerFilter.removeConsumer at line #117
org.apache.activemq.broker.MutableBrokerFilter.removeConsumer at line #123
org.apache.activemq.broker.TransportConnection.processRemoveConsumer at line #580
org.apache.activemq.broker.TransportConnection.processRemoveSession at line #617
org.apache.activemq.command.RemoveInfo.visit at line #74
org.apache.activemq.broker.TransportConnection.service at line #291
org.apache.activemq.broker.TransportConnection$1.onCommand at line #149
org.apache.activemq.transport.MutexTransport.onCommand at line #50
org.apache.activemq.transport.WireFormatNegotiator.onCommand at line #113
org.apache.activemq.transport.AbstractInactivityMonitor.onCommand at line #229
org.apache.activemq.transport.TransportSupport.doConsume at line #83
org.apache.activemq.transport.tcp.TcpTransport.doRun at line #215
org.apache.activemq.transport.tcp.TcpTransport.run at line #197
java.lang.Thread.run at line #722{code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Resolved] (AMQ-3999) Unsubscribing durable subs can be blocked on calls to determine store size, contending with active subs

Posted by "Gary Tully (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AMQ-3999?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gary Tully resolved AMQ-3999.
-----------------------------

    Resolution: Fixed

fix in http://svn.apache.org/viewvc?rev=1378085&view=rev


                
> Unsubscribing durable subs can be blocked on calls to determine store size, contending with active subs
> -------------------------------------------------------------------------------------------------------
>
>                 Key: AMQ-3999
>                 URL: https://issues.apache.org/jira/browse/AMQ-3999
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.6.0
>            Reporter: Gary Tully
>            Assignee: Gary Tully
>             Fix For: 5.7.0
>
>
> Here is the stack trace showing the thread that is making the call to the getMessageCount when a sub is unsubscribing. This causes unnecessary contention with message addition and can result is pauses. Is it really necessary?
> {code}ActiveMQ Transport: tcp:///127.0.0.1:54115
> sun.misc.Unsafe.park at line #-2
> java.util.concurrent.locks.LockSupport.park at line #186
> java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt at line #834
> java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireQueued at line #867
> java.util.concurrent.locks.AbstractQueuedSynchronizer.acquire at line #1197
> java.util.concurrent.locks.ReentrantReadWriteLock$WriteLock.lock at line #945
> org.apache.activemq.store.kahadb.KahaDBStore$KahaDBTopicMessageStore.getMessageCount at line #782
> org.apache.activemq.store.ProxyTopicMessageStore.getMessageCount at line #116
> org.apache.activemq.broker.region.cursors.TopicStorePrefetch.getStoreSize at line #83
> org.apache.activemq.broker.region.cursors.AbstractStoreCursor.resetSize at line #66
> org.apache.activemq.broker.region.cursors.AbstractStoreCursor.gc at line #246
> org.apache.activemq.broker.region.cursors.StoreDurableSubscriberCursor.stop at line #98
> org.apache.activemq.broker.region.DurableTopicSubscription.deactivate at line #171
> org.apache.activemq.broker.region.TopicRegion.removeConsumer at line #164
> org.apache.activemq.broker.region.RegionBroker.removeConsumer at line #473
> org.apache.activemq.broker.jmx.ManagedRegionBroker.removeConsumer at line #266
> org.apache.activemq.broker.BrokerFilter.removeConsumer at line #117
> org.apache.activemq.broker.BrokerFilter.removeConsumer at line #117
> org.apache.activemq.broker.MutableBrokerFilter.removeConsumer at line #123
> org.apache.activemq.broker.TransportConnection.processRemoveConsumer at line #580
> org.apache.activemq.broker.TransportConnection.processRemoveSession at line #617
> org.apache.activemq.command.RemoveInfo.visit at line #74
> org.apache.activemq.broker.TransportConnection.service at line #291
> org.apache.activemq.broker.TransportConnection$1.onCommand at line #149
> org.apache.activemq.transport.MutexTransport.onCommand at line #50
> org.apache.activemq.transport.WireFormatNegotiator.onCommand at line #113
> org.apache.activemq.transport.AbstractInactivityMonitor.onCommand at line #229
> org.apache.activemq.transport.TransportSupport.doConsume at line #83
> org.apache.activemq.transport.tcp.TcpTransport.doRun at line #215
> org.apache.activemq.transport.tcp.TcpTransport.run at line #197
> java.lang.Thread.run at line #722{code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira