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 » General IBM MQ Support » Exclusive consumer concept in Websphere MQ?

Post new topic  Reply to topic
 Exclusive consumer concept in Websphere MQ? « View previous topic :: View next topic » 
Author Message
bharathgvsmq
PostPosted: Mon Feb 09, 2015 1:57 am    Post subject: Exclusive consumer concept in Websphere MQ? Reply with quote

Newbie

Joined: 09 Feb 2015
Posts: 3

Hi Guys,

We are trying for a multiple consumer scenario on the same queue in Websphere MQ. Here is the requirement.

A queue 'TESTQ' will be listened by two consumers(two instances of an application in different servers). We are trying for high availability and also sequential processing of messages i.e., only one consumer(Server1) should get all the messages from the queue and only when it is down the second consumer(Server2) should pick the messages from queue. This is required for the sequential processing of the messages.


I have found that there is a concept called 'Exclusive Consumer' in Active MQ which will do this for us. Please help me with the similar kind of concept in Websphere MQ.

Thanks in advance.
Bharath
Back to top
View user's profile Send private message
zpat
PostPosted: Mon Feb 09, 2015 2:27 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

Open the queue with the option MQOO_INPUT_EXCLUSIVE

Or set this as the default in the queue attributes.

However the second consumer will be unable to open the queue when the first has it open. You should configure the second consumer so that it retries to open the queue at regular intervals.
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
bharathgvsmq
PostPosted: Mon Feb 09, 2015 2:55 am    Post subject: Reply with quote

Newbie

Joined: 09 Feb 2015
Posts: 3

Thank u very much for the reply. I got the MQOPEN part but please tell me which queue attribute do I need to set for MQOO_INPUT_EXCLUSIVE. Setting it in the queue definition level will be really useful.

Thanks again..!
Back to top
View user's profile Send private message
zpat
PostPosted: Mon Feb 09, 2015 3:22 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

It's all in the knowledge center. Default Input Option. Don't forget that this can be overridden by the application. DEFSOPT(EXCLUSIVE)
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
bharathgvsmq
PostPosted: Mon Feb 09, 2015 6:04 am    Post subject: Reply with quote

Newbie

Joined: 09 Feb 2015
Posts: 3

Thank u very much for that zpat. That was really helpful
Back to top
View user's profile Send private message
gbaddeley
PostPosted: Mon Feb 09, 2015 4:03 pm    Post subject: Reply with quote

Jedi Knight

Joined: 25 Mar 2003
Posts: 2538
Location: Melbourne, Australia

Be aware that MQ does not guarantee the sequence of messages on a queue. The time order they are put by producer app(s) is not necessary the order than consumer app(s) will get them. A requirement for message sequence affinity will need to be part of the app design and coding. This usually involves temporarily storing the messages in a DB or using some other marshalling / delayed / missing message handling techniques. The MQ message group feature may also offer a solution.
_________________
Glenn
Back to top
View user's profile Send private message
zpat
PostPosted: Mon Feb 09, 2015 10:43 pm    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

However if they are put on the queue by one producer, with the same priority, and there is only one route to the other QM (or it is the same queue manager) then the order will be the same.
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General IBM MQ Support » Exclusive consumer concept in Websphere MQ?
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.