Author |
Message
|
smdavies99 |
Posted: Mon Aug 24, 2015 11:13 pm Post subject: When can a PCF reply be delayed? |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
I'm doing some dev on a program that gets some queue attributes namely, the Queue Depth. This is fed to a monitoring system that does not have MQ support !!!!
The basic operation is this
Code: |
- get List of queues
for each queue in list
construct PCF Message
write message to SYSTEM.COMMAND.QUEUE using MQPUT
READ Response with a 2 second timeout with MQGET
end for
format output message
send to monitoring system
|
Every so often when the system is loaded I get a message that is one queue short and a message is left on the Response Queue
My logging indicates that when this happens the MQGET recieves a 2033 Reason code.
Is a 2 second timeout reasonable? or should I make it Longer?
any thoughts most welcome. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
mqjeff |
Posted: Tue Aug 25, 2015 4:26 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
I think that, rather than using a second timeout, I would increase the first one to 4 seconds or etc.
The MQGET does only consume the time it actually needs to return a message, so it doesn't always consume the full timeout. You know that, of course, but it's always nice to have someone else job one's memory.
I would then put in specific retry logic for a 2033.
I might also look at qdepth events rather than doing specific inquiries. _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Aug 25, 2015 4:43 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
And remember there was a glitch, I believe in early version 8 where a pcf response was left on the response queue (incorrect # of responses...). Make sure all your servers are at an adequate level.  _________________ MQ & Broker admin |
|
Back to top |
|
 |
smdavies99 |
Posted: Tue Aug 25, 2015 4:43 am Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
mqjeff wrote: |
I think that, rather than using a second timeout, I would increase the first one to 4 seconds or etc.
The MQGET does only consume the time it actually needs to return a message, so it doesn't always consume the full timeout. You know that, of course, but it's always nice to have someone else job one's memory.
I would then put in specific retry logic for a 2033.
I might also look at qdepth events rather than doing specific inquiries. |
I've changed the timeout to 4 seconds.
So far I've measured 239 operations and the elapsed time varies from 0.0263 seconds to 1.0914 seconds. I need to do some more loadings. [1] This is for 30 different queues.
As regards QDepth events, getting the change needed to get these enabled would take approx 6 months. It took me almost 11 months from first proposal to going ahead and doing it to get the QMGR upgraded from V7.0.1.9 to 8.0.0.3
And they need the data yesterday.
[1]I am measuring the time it takes from the start of the operation to the end. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Aug 25, 2015 4:46 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Might be easier / faster to get the queue depth for all queues with depth > 0 and weed out in the program the ones you don't want...  _________________ MQ & Broker admin |
|
Back to top |
|
 |
smdavies99 |
Posted: Tue Aug 25, 2015 9:43 pm Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
I've increased the timeout to 4 seconds. So far I've seen three elapsed times greater than 1 second. This is after some 5000 runs of the application. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
PeterPotkay |
Posted: Thu Aug 27, 2015 4:28 pm Post subject: |
|
|
 Poobah
Joined: 15 May 2001 Posts: 7722
|
I have had to use wait times up to 5 seconds in order to process things like a list of channel statuses for a QM with thousands of active MQ Client connections. _________________ Peter Potkay
Keep Calm and MQ On |
|
Back to top |
|
 |
smdavies99 |
Posted: Thu Aug 27, 2015 10:43 pm Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
PeterPotkay wrote: |
I have had to use wait times up to 5 seconds in order to process things like a list of channel statuses for a QM with thousands of active MQ Client connections. |
Thanks Peter. That is useful to know. I've made the timeout configurable but these queue managers are dog simple when compared to yours. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
|