You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by mohank <mo...@gmail.com> on 2011/08/26 15:02:24 UTC

Get Message Based on ID

Pals,

I have Created one producer which is the sender and a consumer which is the
receiver. The messages sent by the producer are queue up in the running
broker server. i can able to see all the details using JMX. I need to know
whether Message Consumer has any option to receive message based on IDs like
*Message ID or Correlation ID*? If so, can any one guide me to do this.

Eg : My Queue name is "Message.Queue". It has messages with message and
correlation id. i need to query like queue name and message id or
correlation id to get the message.

Thanks in advance.

--
View this message in context: http://activemq.2283324.n4.nabble.com/Get-Message-Based-on-ID-tp3770798p3770798.html
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.

Re: Get Message Based on ID

Posted by mohank <mo...@gmail.com>.
hi Dejan Bosanac,

Thanks for your response.


--
View this message in context: http://activemq.2283324.n4.nabble.com/Get-Message-Based-on-ID-tp3770798p3772901.html
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.

Re: Get Message Based on ID

Posted by mohank <mo...@gmail.com>.
Hi,

Am using Apache ActiveMQ. My Broker Service is running in a Server. I
haven't explicitly created any *jndi* properties to set the
*InitialContext*. Am accessing the broker service by
*ActiviMQConnectionFactory *(With the server TCP URI) object to send and
recieve the messages through queues. Its working fine. As i referred, we can
able to create a *QueueReciever *object by the look up the server jndi
properties?

Is there any way to create *QueueReciever *object without creating *JNDI
InitialContext*?

Thanks in advance


--
View this message in context: http://activemq.2283324.n4.nabble.com/Get-Message-Based-on-ID-tp3770798p3773216.html
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.

Re: Get Message Based on ID

Posted by Dejan Bosanac <de...@nighttale.net>.
Take a look at message selectors http://activemq.apache.org/selectors.html

Regards
-- 
Dejan Bosanac - http://twitter.com/dejanb
-----------------
The experts in open source integration and messaging - http://fusesource.com
ActiveMQ in Action - http://www.manning.com/snyder/
Blog - http://www.nighttale.net


On Fri, Aug 26, 2011 at 3:02 PM, mohank <mo...@gmail.com> wrote:

> Pals,
>
> I have Created one producer which is the sender and a consumer which is the
> receiver. The messages sent by the producer are queue up in the running
> broker server. i can able to see all the details using JMX. I need to know
> whether Message Consumer has any option to receive message based on IDs
> like
> *Message ID or Correlation ID*? If so, can any one guide me to do this.
>
> Eg : My Queue name is "Message.Queue". It has messages with message and
> correlation id. i need to query like queue name and message id or
> correlation id to get the message.
>
> Thanks in advance.
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/Get-Message-Based-on-ID-tp3770798p3770798.html
> Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.
>