On 2 April 2010 12:30, dcheckoway <dchecko...@gmail.com> wrote:

>
> I could use some help understanding memory usage & limits in activemq.
>  5.3.1
> is what I'm running, fwiw.
>
> 1. Out of the box, <systemUsage> in activemq.xml is commented out.  I'm
> passing ACTIVEMQ_OPTS="-Xmx2048M ...".  What is the default behavior in
> that
> case?  Does that mean activemq will take advantage of the 2gb heap by
> default, or do I need to configure <memoryUsage> explicitly?  If it needs
> to
> be explicit, can I safely set <memoryUsage limit="2 gb"/> ?  If not, what's
> a recommended setting given -Xmx2048M?
>
> No, there are some hardcoded defaults for systemUsage think default for
memory is 64MB.
You need to take into account the expected number of destinations and
connections and producers/consumers as these will require memory.
Something like 70% of available heap is a reasonable initial gestimate.


> 2. On <policyEntry>, what exactly does "memoryLimit" do?  I have
> producerFlowControl="false", and I wasn't sure if memoryLimit only applies
> when producer flow control is enabled, or what?
>

That limits the amount of memory consumed by messages on that destination.
When that limit is reached, enqueues block unless systemUsage limits are
reached and message are spooled to disk. With producerFlowControl, the
producer is blocked rather than the destination in the broker.

>
> 3. What happens if you set the <policyEntry> elements' memoryLimit to the
> same size as your heap and/or <memoryUsage limit>?
>

that destination can block all other destinations by consuming all of the
memory resources.


> I'd like to understand the interaction of all of these factors.  Any info
> you can provide would be MUCH appreciated!!!
>
> Thanks,
> Dan
> --
> View this message in context:
> http://old.nabble.com/Help-understanding-memory-usage-limits-tp28118112p28118112.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>


-- 
http://blog.garytully.com

Open Source Integration
http://fusesource.com

Reply via email to