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 2009/11/12 11:02:02 UTC

[jira] Assigned: (AMQ-2487) MemoryUsage not properly accounted for when expiring messages to DLQ: can lead to hang.

     [ https://issues.apache.org/activemq/browse/AMQ-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gary Tully reassigned AMQ-2487:
-------------------------------

    Assignee: Gary Tully

> MemoryUsage not properly accounted for when expiring messages to DLQ: can lead to hang.
> ---------------------------------------------------------------------------------------
>
>                 Key: AMQ-2487
>                 URL: https://issues.apache.org/activemq/browse/AMQ-2487
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.4.0
>         Environment: N/A
>            Reporter: Colin MacNaughton
>            Assignee: Gary Tully
>             Fix For: 5.4.0
>
>         Attachments: AMQ-2487patch.txt
>
>
> Given the following broker destination policy
> {code:xml} 
>     <destinationPolicy>
>       <policyMap>
>         <policyEntries>
>           <policyEntry topic=">" producerFlowControl="true"
>             memoryLimit="1mb">
>             <pendingSubscriberPolicy>
>               <vmCursor />
>             </pendingSubscriberPolicy>
>           </policyEntry>
>           <policyEntry queue=">" producerFlowControl="true"
>             memoryLimit="1mb">
>             <!--
>               Use VM cursor for better latency For more information,
>               see: http://activemq.apache.org/message-cursors.html
>             -->
>             <pendingQueuePolicy>
>               <vmQueueCursor />
>             </pendingQueuePolicy>
>           </policyEntry>
>         </policyEntries>
>       </policyMap>
>     </destinationPolicy>
> {code}
> If I send message to queue://TESTQ1 with an expiration of 1second, with an unreliable/slow receiver, the publisher eventually hangs sending to the queue. The underlying problem is that when the message is expired to the DLQ the MemoryUsage reference is left pointing the TESTQ1's memory limiter, instead of being reset to the DLQ limiter, and when it is added to the DLQ, TESTQ1's memory limiter is updated counteracting the decrement that is done by the TESTQ1 when the message is expired. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.