ActiveMQ and maxPageSize -


i set maxpagesize larger number default 200.

this how set in activemq.xml file:

<destinationpolicy>             <policymap>               <policyentries>               ---                 <policyentry queue=">" producerflowcontrol="true" memorylimit="1mb" maxpagesize="some_large_number">                 </policyentry>               </policyentries>             </policymap>         </destinationpolicy> 

this change helps me number of messages in queue using queuebrowser.getenumeration() returned 200 if number of messages in queue greater 200.

please see: http://docs.oracle.com/javaee/1.4/api/javax/jms/queuebrowser.html queuebrowser.getenumeration().

what side effect of changing maxpagesize 200 1000? affect broker's performance anyway?

i not seeing documentation property other "maximum number of persistent messages page store @ time" on page:

http://activemq.apache.org/per-destination-policies.html

thanks time!

max page size indicates number of messages loaded memory, impact is.. consume more memory.

reading between lines though, reason doing anti-pattern. queue browsing part of application misuse of messaging - message queue works best when treated queue. first in, first out. not array scan see whether message has arrived.

you better off consuming each of messages, , either:

  1. sorting them onto bunch of other queues depending on payload , processing second level of queues differently, or
  2. storing payloads database , selecting based on content.

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -