activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Márcio Geovani Jasinski <marci...@gmail.com>
Subject Re: One Sender - Many Receivers behavior
Date Mon, 01 Mar 2010 23:16:01 GMT
Hi Zak,

Thanks for your reply.
I thought about use sub/pub (topic) instead of sender/receiver (queue) but
we have a case where each consumer should take one message and remove from
that queue to avoid process it more than once.

In a pub/sub structure each subscriber will consume a published message. So
Message (M001) will be consumed by each subscriber registered...

That's why we are using Send/Receive - if message (M001) was taken from the
queue by one receiver, should not be taken by others. And this scenario
works pretty well when sender keep sending messages to our queue. Once it
stops and the queue is quite big, slowly the receivers stop taking data from
this queue and in the end I have only one receiver working even with a big
queue ahead.

I'm not sure if I could explain correctly the issue. Is it a case to use
sub/pub? I mean can I ensure that each message will be taken only once?

Thanks.

2010/3/1 bzaks1424 <bzaks1424@gmail.com>

>
> I'm no expert on ActiveMQ - but it sounds like you should be using a Topic
> rather than a queue.
>
>
> Márcio Geovani Jasinski wrote:
> >
> > Hi,
> >
> > I´m having a interesting behavior with JMS and MQ components since last
> > week.
> > Basically we did a Send/Receiver program to test if it´s many consumers
> > could process the content published in one queue. The example works
> pretty
> > well when sender is running together with all receiver instances.
> >
> > The strange thing happen when:
> > 1. Start ONE producer and fill a queue with 100000 messages - then
> > producer
> > is done (Running but not sending).
> > 2. Start TREE consumers to share the content of messages in the queue.
> >
> > In the beginning all instances are able to consume few messages from the
> > queue. But after a long time, just consumer number ONE will pull data
> from
> > the queue. Even when the queue contains thousand of messages!
> > The problem happens faster when I stop all consumers after few messages
> > pulled from the queue. When I restart all receivers, just instance number
> > one keep working...
> >
> > This scenario happens with activemq and also with Glassfish MQ.
> >
> > It´s looks like the broker doesn´t reconizer more than one receiver when
> > sender isn´t publishing any messages.
> >
> > Does anybody had this problem before?
> >
> > Thanks.
> >
> > Regards.
> > --
> > Márcio Geovani Jasinski
> > Blumenau, Santa Catarina
> > Fone: +55 47 9653 4899
> >
> >
>
> --
> View this message in context:
> http://old.nabble.com/One-Sender---Many-Receivers-behavior-tp27748124p27748738.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>


-- 
Márcio Geovani Jasinski
Blumenau, Santa Catarina
Fone: +55 47 9653 4899

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message