ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Java / JMS » Mutliple Queue consumers

Post new topic  Reply to topic
 Mutliple Queue consumers « View previous topic :: View next topic » 
Author Message
girim
PostPosted: Tue May 22, 2007 8:13 pm    Post subject: Mutliple Queue consumers Reply with quote

Newbie

Joined: 22 May 2007
Posts: 2
Location: Chennai India

In my environment I have four queue consumers (listeners) consuming messages from the same queue. Some times, in a very rare scenario, the same message is being consumed by more than 1 consumer ending up in duplication of the process. Is there a way to over come this by still having multiple consumers pointing to the same queue.
Back to top
View user's profile Send private message
marcin.kasinski
PostPosted: Tue May 22, 2007 10:50 pm    Post subject: Re: Mutliple Queue consumers Reply with quote

Sentinel

Joined: 21 Dec 2004
Posts: 850
Location: Poland / Warsaw

athresh2001 wrote:
In my environment I have four queue consumers (listeners) consuming messages from the same queue. Some times, in a very rare scenario, the same message is being consumed by more than 1 consumer ending up in duplication of the process. Is there a way to over come this by still having multiple consumers pointing to the same queue.



Can you duplicate it problem ?
Maybe it is problem with sending application. have you checked it ?
Do you log messages on sending and receiving side ?
_________________
Marcin
Back to top
View user's profile Send private message Visit poster's website
girim
PostPosted: Tue May 22, 2007 10:54 pm    Post subject: Reply with quote

Newbie

Joined: 22 May 2007
Posts: 2
Location: Chennai India

Yes I was able to duplicate it. Actually when we have just one consumer we did not get this problem, when we added another consumer for the same queue, we had this problem. There is no problem with the application sending the messages. This we were able to confirm by stopping all the listeners to the queue and verified the queue depth and the number of messages transmitted by the sending application.
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed May 23, 2007 3:39 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Is it possible that one consumer is rolling the message back?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
zpat
PostPosted: Wed May 23, 2007 4:08 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

MQ does not allow the same message to be consumed more than once.

We have many multi-threaded JMS applications sharing queues.

You are either browsing it or getting under syncpoint and then it is rolled back (check the MQMD.back count) and re-processed.

If you MQGET under syncpoint you must check for backed out messages and send them to a poison queue if repeatedly processesd or you will get a loop.
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed May 23, 2007 4:21 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

athresh2001 wrote:
Yes I was able to duplicate it.


If you're absolutely certain it's not an application issue (e.g. a rollback as jefflowrey suggests) than you need to raise a PMR with IBM, especially if you're using the latest version. It would be a very serious bug if it's been introduced.

Certainly this works on previous versions I've done it on.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Cyrille Le Clerc
PostPosted: Wed May 23, 2007 7:54 am    Post subject: Re: Mutliple Queue consumers Reply with quote

Novice

Joined: 23 May 2007
Posts: 12
Location: France

Hello athresh,

Just to check, what is the isolation level of these consumers ?

Do these consumers share the same Virtual Machine ? The same JMS Connection Factory ? The same JMS connection ? The same JMS session (warning : JMS sessions are NOT thread safe) ?

Are your sessions transacted ? Whats is the acknowledge mode ?

If the consumers share some java components, can you show us the simplified code (just the JMS stuff) ?


athresh2001 wrote:
... having multiple consumers pointing to the same queue.


Cyrille
_________________
Cyrille Le Clerc
cyrille@cyrilleleclerc.com
cleclerc@xebia.fr
http://blog.xebia.fr
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » Mutliple Queue consumers
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.