You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by kenjackson <kj...@gmail.com> on 2008/09/12 01:32:27 UTC

Sending

Hi,

I'm an ActiveMQ newbie and I searched through the documentation, but I'm not
sure if the functionality I was looking for is available.  

Is there any way to have subscribers to a queue or topic get messages based
on their username?  For example, if I have two users connected to a topic,
can I push a message onto the queue such that only one of them will receive
this message?

I tried searching under "Security" but this deals with strictly
authentication, but I wasn't sure if there was a way to send messages to
specific users.

Thanks,

Ken
-- 
View this message in context: http://www.nabble.com/Sending-tp19446799p19446799.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: Sending

Posted by James Strachan <ja...@gmail.com>.
See
http://activemq.apache.org/how-does-a-queue-compare-to-a-topic.html

maybe you just need a temporary queue, so each client has their own
queue until they shut down?

2008/9/12 kenjackson <kj...@gmail.com>:
>
> Hi,
>
> I'm an ActiveMQ newbie and I searched through the documentation, but I'm not
> sure if the functionality I was looking for is available.
>
> Is there any way to have subscribers to a queue or topic get messages based
> on their username?  For example, if I have two users connected to a topic,
> can I push a message onto the queue such that only one of them will receive
> this message?
>
> I tried searching under "Security" but this deals with strictly
> authentication, but I wasn't sure if there was a way to send messages to
> specific users.
>
> Thanks,
>
> Ken
> --
> View this message in context: http://www.nabble.com/Sending-tp19446799p19446799.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>



-- 
James
-------
http://macstrac.blogspot.com/

Open Source Integration
http://open.iona.com

Re: Sending message to specific recipients based on username

Posted by Joe Fernandez <jo...@ttmsolutions.com>.
You can use a combination of message property and selector. For example, your
producer defines a  message property - call it 'consumerName' - and sets its
value to that of the target consumer's username.  The consumer can then use
a selector to read only those messages with a consumerName property having a
value equal to its username.  

http://activemq.apache.org/how-do-i-consume-a-specific-message.html

Or you can have each consumer read off a queue whose physical name matches
its username and then implement a content based router pattern.

http://activemq.apache.org/camel/content-based-router.html

Joe
Get a free ActiveMQ user guide @ http://www.ttmsolutions.com 




 

kenjackson wrote:
> 
> Hi,
> 
> I'm an ActiveMQ newbie and I searched through the documentation, but I'm
> not sure if the functionality I was looking for is available.  
> 
> Is there any way to have subscribers to a queue or topic get messages
> based on their username?  For example, if I have two users connected to a
> topic, can I push a message onto the queue such that only one of them will
> receive this message?
> 
> I tried searching under "Security" but this deals with strictly
> authentication, but I wasn't sure if there was a way to send messages to
> specific users.
> 
> Thanks,
> 
> Ken
> 

-- 
View this message in context: http://www.nabble.com/Sending-message-to-specific-recipients-based-on-username-tp19446799p19448025.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.