You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by mlukica <ma...@tis.hr> on 2008/06/10 11:52:51 UTC

queue.send throws ResourceAllocationException without checking usageManager when sendFailIfNoSpace is set in AMQ 4.1.2

Affected version: AMQ 4.1.2

org.apache.activemq.broker.region.Queue send(ConnectionContext, Message)
method always throws ResourceAllocationException if sendFailIfNoSpace is
set, producerFlowControl is enabled, message response is not required and
network connection is not used to connect to broker.

In this case thread execution ends up in following code block:
...
            } else {
                if (usageManager.isSendFailIfNoSpace() ) {
                    throw new javax.jms.ResourceAllocationException("Usage
Manager memory limit reached");
                } else {
                    while( !usageManager.waitForSpace(1000) ) {
                        if( context.getStopping().get() )
                            throw new IOException("Connection closed, send
aborted.");
                    }
                }
            }

... usageManager is never checked for space prior to throwing
ResourceAllocationException("Usage Manager memory limit reached"), and no
message can be sent to this queue, regardless of the usageManager set on
queue.
-- 
View this message in context: http://www.nabble.com/queue.send-throws-ResourceAllocationException-without-checking-usageManager-when-sendFailIfNoSpace-is-set-in-AMQ-4.1.2-tp17751662p17751662.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: queue.send throws ResourceAllocationException without checking usageManager when sendFailIfNoSpace is set in AMQ 4.1.2

Posted by mlukica <ma...@tis.hr>.
Created  AMQ-1789 for this issue.
-- 
View this message in context: http://www.nabble.com/queue.send-throws-ResourceAllocationException-without-checking-usageManager-when-sendFailIfNoSpace-is-set-in-AMQ-4.1.2-tp17751662p17771954.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.