activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From asarkari <abhinav.sark...@gmail.com>
Subject Message priority and message selector - Active MQ version 5.4
Date Fri, 30 Jan 2015 02:03:37 GMT
Here is my use case.. 

I have two producers sending messages to a queue and there are two consumers
on this queue. 

Producer one sets a message header on the message e.g. MyName=one and
priority 8. 

Producer two sets message header MyName=two and priority 6. 

The consumers use message selector MyName="one" and MyName="two". 

The producers are continuously sending messages and consumers are also
active. 

Lets say at certain stage, the queue has 10 messages with header value one
and priority 8 and 5 messages with header value two and priority 6. 

Now what happens.. does the consumer 2 instantly receive the 5 messages that
it is eligible to receive via message selector or it would receive these
only after consumer one has consumed the other 10 messages which had higher
priority.. 


Essentially, my question is how does the broker handle message selection and
priority i.e. which one gets applied first. I went through Active MQ docs
but couldn't find an answer. 

I can test the behavior myself, but would that always be consistent? Does
Active MQ has a clear working on priority and message selection? 



--
View this message in context: http://activemq.2283324.n4.nabble.com/Message-priority-and-message-selector-Active-MQ-version-5-4-tp4690692.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Mime
View raw message