|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Accuracy of expiry |
« View previous topic :: View next topic » |
Author |
Message
|
tonym |
Posted: Mon Sep 22, 2003 11:50 pm Post subject: Accuracy of expiry |
|
|
Novice
Joined: 22 Sep 2003 Posts: 11
|
I put a message on a queue and then, at a later stage remove that message from the queue. No intercommunication is involved - the message has remained on that single queue for the entire time. Will the decrement in the expiry accurately represent (within a tenth of a second accuracy) the time the message was on the queue?
I ask because somewhere in the manuals it says "...the expiration time is treated as approximate, and the value need not be decremented to reflect small time intervals". I'm wondering what is meant by "small time intervals"
cheers
Tony |
|
Back to top |
|
 |
dgolding |
Posted: Tue Sep 23, 2003 12:36 am Post subject: |
|
|
 Yatiri
Joined: 16 May 2001 Posts: 668 Location: Switzerland
|
Hi Tony,
There isn't a ticking clock on the message - MQ doesn't set a timer on the message and then "wakes up" when it has expired. An expired message can sit on a queue for months, but only when the message IS BROWSED does MQ remove it.
There are some utilities kicking around that do a browse on all queues to clear expired messages. They do take up space, and count as part of the "curdepth" so a queue could be filled with expired messages.
HTH |
|
Back to top |
|
 |
tonym |
Posted: Tue Sep 23, 2003 1:37 am Post subject: |
|
|
Novice
Joined: 22 Sep 2003 Posts: 11
|
I'm not asking about mq processing once a message is expired. I was wondering how accurately the expiry property was decremented. Basically, if I calculate "original expiry" minus "remaining expiry", will the result always reflect the exact (to a tenth of a second) length of time the message has been on the queue?
A question for IBMers, probably! |
|
Back to top |
|
 |
dgolding |
Posted: Tue Sep 23, 2003 2:31 am Post subject: |
|
|
 Yatiri
Joined: 16 May 2001 Posts: 668 Location: Switzerland
|
No idea I'm afraid, but if you want to know the time it's been on the queue - just subtract the PUT time (in GMT) from the system time (not local time - you have to get the current GMT time)....
To be honest, AFAIK the time remaining is calculated by MQ when the message is GET'd - again, AFAIK the queue manager does not process these expiry dates in real-time - that would be a tremendous overhead! |
|
Back to top |
|
 |
mrlinux |
Posted: Tue Sep 23, 2003 7:00 am Post subject: |
|
|
 Grand Master
Joined: 14 Feb 2002 Posts: 1261 Location: Detroit,MI USA
|
When you browse the queue you will get the updated expiry time, now how accurate it is another story, my guess is that it is fairly accurate, I
was just playing with this right now for something I need to do _________________ Jeff
IBM Certified Developer MQSeries
IBM Certified Specialist MQSeries
IBM Certified Solutions Expert MQSeries |
|
Back to top |
|
 |
PeterPotkay |
Posted: Tue Sep 23, 2003 7:35 am Post subject: |
|
|
 Poobah
Joined: 15 May 2001 Posts: 7722
|
The comment in the manuals you are referring to is for when an application picks up a request message, processes it, and then puts out the reply message.
Usually, the application simply passes along the expiry value from the request into the reply message. This is OK because the app is very fast and processes the message in less than a tenth of a second. If the app needs more time than this, say 3 seconds, a good MQ app will take 3 seconds off of the captured request message's expiry time before putting out the reply message.
The reason for this is because the app waiting for the reply may be looking at the Expiry value as a means of knowing how long the message was "out there". Since Expiry is only decremented while a message is sitting on a queue, it will not be decremented while on the network between QMs and not while in any intermediate apps. Network time is almost always in milliseconds, so it can be ignored. Stuck in an app for several seconds or minutes puts the responsability on the app to decrement the Expiry value, hence the comment in the manuals. _________________ Peter Potkay
Keep Calm and MQ On |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|