IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

timeout parameter


IBM Mainframe Forums -> Java & MQSeries
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
ibmmainframe1

New User


Joined: 26 Jul 2005
Posts: 64
Location: India

PostPosted: Fri Nov 20, 2009 5:01 pm
Reply with quote

How to set timeout parameter as 15mins for MQ messages.
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Fri Nov 20, 2009 7:59 pm
Reply with quote

Please explain your request. Is this for waiting to GET MSGs?
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Fri Nov 20, 2009 8:20 pm
Reply with quote

Options are either Expiry, in tenths of a second or WaitInterval in thousandths or a second. The former is set in MQMD whend MQPUTting the message, the latter in the MQMD in conjunction with MQGMO_WAIT in Get Options.

Garry
Back to top
View user's profile Send private message
ibmmainframe1

New User


Joined: 26 Jul 2005
Posts: 64
Location: India

PostPosted: Fri Nov 20, 2009 9:28 pm
Reply with quote

Hi Garry & Bill,

Thanks for your quick responses.

My MQPUT call looks like this. Pls advise where to add the timeout parameter. I appreciate it.

Code:
CALL "MQPUT" USING WS-HCONN-HANDLE           
                   WS-HOBJ-HANDLE           
                   MQMD                     
                   MQPMO                     
                   WS-DATALENGTH             
                   FORMATTED-OUTPUT-MSG-XML 
                   MQCFH-COMPCODE           
                   MQCFH-REASON             
END-CALL                                     
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Fri Nov 20, 2009 9:35 pm
Reply with quote

Since this is an MQPUT, you are speaking of an Expiry Interval, not a timeout.

Code:
  MQMD.Expiry = 9000;  /* 15min * 60sec * 10 */



What MQMD are you going to use for an MQGET for a reply?(if you expect one). Don't re-use the same MQMD - that's asking for trouble.

Garry.
Back to top
View user's profile Send private message
ibmmainframe1

New User


Joined: 26 Jul 2005
Posts: 64
Location: India

PostPosted: Thu Nov 26, 2009 2:48 pm
Reply with quote

Hi Garry thanks a lot for your response.

My understanding is
Expiry & non-persistence should go together.


Pls correct me.

Thanks.
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Thu Nov 26, 2009 3:03 pm
Reply with quote

Quote:
My understanding is
Expiry & non-persistence should go together.


Your understanding is incorrect. Expiry applies to both persistent and non-persistent messages and specifies the interval after which MQ is to discard a message. An expired message can contribute to queue-depth, but is inaccessible to applications pending its actual removal from the queue.

Persistence/non-persistence determines whether a message survives a restart of the QueueManager - non-persistent messages are lost on QueueManager restart, regardless of Expiry setting.

It is likely, where persistence is required, that the Expiry should also be set to MQEI_UNLIMITED.

Garry.
Back to top
View user's profile Send private message
ibmmainframe1

New User


Joined: 26 Jul 2005
Posts: 64
Location: India

PostPosted: Thu Nov 26, 2009 10:38 pm
Reply with quote

Thanks for clear explanation Gary.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> Java & MQSeries

 


Similar Topics
Topic Forum Replies
No new posts Using the Jobname parameter in a Qual... ABENDS & Debugging 1
No new posts Demand with DEADLINE TIME parameter CA Products 4
No new posts Option DYNALLOC second parameter. DFSORT/ICETOOL 11
No new posts Writing the output file name from a p... JCL & VSAM 7
No new posts Reference for COND parameter. JCL & VSAM 1
Search our Forums:

Back to Top