-
1. Receive message many times
ataylor Jan 19, 2011 5:47 AM (in response to asterisk)iirc this is a bug that has been fixed in the latest version
-
2. Receive message many times
timfox Jan 19, 2011 5:49 AM (in response to asterisk)Are you sure you don't simply have 15 MDB instances consuming from the topic?
With a topic, each consumer gets a copy of the message.
IIRC default MDB pool size is something like 15.
-
3. Receive message many times
asterisk Jan 19, 2011 6:00 AM (in response to timfox)After checking the JMX console I can see 15 entries like this:
address="jms.topic.testTopic",module=Core,name="1b8d41d5-a427-4b7e-a906-5bca437e2dbc",type=Queue
So it seems you are right. Even if I wonder why type is Queue, it should be Topic, right?
Is the behaviour of HornetQ different for topics than in JBoss messaging? I am actually migratin a big application from JBoss 4.0.4 to 5.1.
Do I have to use a Topic or a Queue, if I want to trigger some parallel jobs using an MDB?
Thanks!
-
4. Receive message many times
timfox Jan 19, 2011 6:50 AM (in response to asterisk)The type should be Queue. In HornetQ each topic subscription is just a queue registered to the same address. (See user manual)
So, it looks like HornetQ is behaving correctly. You've created 15 topic subscriptions so each one will receive a copy of the message.
If you only want one MDB to receive a particular message deploy a JMS queue and set your MDB to consume from that.
For more clarification on the differences between a queue and topic, the JMS spec and JMS tutorial (see wiki) are good places to start. -
5. Receive message many times
clebert.suconic Jan 19, 2011 9:56 AM (in response to asterisk)There was a bug on 2.0.GA's Resource adapter. It would create one one subscription for each instances on the MDB.
It should be fixed on the latest released and trunk.