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 Discussion » MQClient Connection/Get with Wait

Post new topic  Reply to topic
 MQClient Connection/Get with Wait « View previous topic :: View next topic » 
Author Message
BarryB
PostPosted: Mon Jul 19, 2004 10:46 am    Post subject: MQClient Connection/Get with Wait Reply with quote

Acolyte

Joined: 01 Jul 2004
Posts: 53
Location: Vernon Hills, Il

Is it not recommended to have an application use a get with wait unlimited when the app resides on an MQClient Windows box which is awaiting messages on the MQServer residing on AIX? It appears when our application does the get with wait unlimited, the app just hangs and never processes the messages on the queue.

1) We have already checked that we are using the correct get options
2) We have checked the MQ infrastructure

We cannot find anything or any errors that occur when the app hangs. Is it recommended not to use the get with wait unlimited when using a client connection? If so, where can I find this documentation?
Back to top
View user's profile Send private message
kirani
PostPosted: Mon Jul 19, 2004 11:17 am    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Is this related to the problem described in this tread,
http://www.mqseries.net/phpBB2/viewtopic.php?p=66159

There is nothing wrong in using get with unlimited wait in a Client or server application.

Is it that your program is hanging (not responding at all) or the application is unable to get message from the queue?
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
BarryB
PostPosted: Mon Jul 19, 2004 11:47 am    Post subject: Reply with quote

Acolyte

Joined: 01 Jul 2004
Posts: 53
Location: Vernon Hills, Il

It is the application just hanging. Someone advised they wouldnt recommend using a get with wait on an MQClient channel. Do you agree?
Back to top
View user's profile Send private message
bower5932
PostPosted: Mon Jul 19, 2004 11:54 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Aug 2001
Posts: 3023
Location: Dallas, TX, USA

I've used get with waits from a client. If you aren't going to wait, then are you going to re-issue the MQGET immediately? You definitely need to make sure that you specify the fail if quiescing option so that the get will return if the qmgr is shutting down.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
kevinf2349
PostPosted: Mon Jul 19, 2004 12:09 pm    Post subject: Reply with quote

Grand Master

Joined: 28 Feb 2003
Posts: 1311
Location: USA

Hmmm I didn't say MQGET with wait was not recommended....if I did I certainly retract that statement. What I meant to say...and thought I had said was that I personally wouldn't do a MQGET with a wait unlimited.

[/b]
Back to top
View user's profile Send private message
kirani
PostPosted: Mon Jul 19, 2004 12:45 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Barry,

As bower5932 said, use correct options like "fail if quiescing", etc in such applications.
Is it possbile to put some trace within your program to see where exactly it's hanging. May be its waiting for some resource. Put some printf/cout statements in your programs.
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
zpat
PostPosted: Tue Jul 20, 2004 5:15 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

My recommendation is ALWAYS to use GET with WAIT, rather than keeping "polling" which is very inefficient. We have thousands of MQ Clients (on all our PCs) doing MQGET WAITs all day long.

Do this:

(set the wait interval to perhaps 60 seconds)

MQGET with options CONVERT, WAIT, FAIL_IF_QUIESCING.

If MQ quiescing then exit

If MQ has passed back a message then process it as required.

If no message data available then null

If other MQ errors then handle appropriately

If client app being stopped (operator command etc) then exit

Repeat forever
Back to top
View user's profile Send private message
BarryB
PostPosted: Tue Jul 20, 2004 5:30 am    Post subject: Reply with quote

Acolyte

Joined: 01 Jul 2004
Posts: 53
Location: Vernon Hills, Il

Thanks all...I will try this.
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 Discussion » MQClient Connection/Get with Wait
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.