Author |
Message
|
atoms |
Posted: Mon Apr 03, 2006 8:13 am Post subject: Non-persistant messages survives a queue manager restart...? |
|
|
Apprentice
Joined: 10 Jun 2005 Posts: 27
|
I noticed that when I did a "controlled" restart of a queue manager, messages that were stacked on a queue defined as "non-persistant" actually "survived" the restart. I had expected that the messages would be gone since they were not persistant. Was it only because I did a controlled restart that the queue manager was able to keep the messages? I mean, shouldn't non-presistant messages be lost when you restart the queue manager?
Just out of curiosity... |
|
Back to top |
|
 |
mvic |
Posted: Mon Apr 03, 2006 8:42 am Post subject: Re: Non-persistant messages survives a queue manager restart |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
atoms wrote: |
messages that were stacked on a queue defined as "non-persistant" |
Please explain further - how exactly was the queue defined as non-persistent?
Quote: |
actually "survived" the restart. I had expected that the messages would be gone since they were not persistant |
A non-persistent message can survive a queue manager restart, if (and only if) the queue that contains it is defined with NPMCLASS(HIGH).
See http://publib.boulder.ibm.com/infocenter/wmqv6/v6r0/topic/com.ibm.mq.csqzaj.doc/csqzaj1048.htm (scroll down or search for NPMCLASS) |
|
Back to top |
|
 |
EddieA |
Posted: Mon Apr 03, 2006 9:48 am Post subject: |
|
|
 Jedi
Joined: 28 Jun 2001 Posts: 2453 Location: Los Angeles
|
Quote: |
on a queue defined as "non-persistant" |
Actually, persistence is an attribute of a message, and once that message has been PUT, it's persistence value cannot be changed.
The attribute on the queue, could be considered a "helper", in that it is the persistence that a message will get, if the putting application does not explicitly set the persistence.
So, to answer your question, you also need to look at the messages themseves, to see what persistence they have.
Cheers, _________________ Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0 |
|
Back to top |
|
 |
kevinf2349 |
Posted: Mon Apr 03, 2006 9:50 am Post subject: |
|
|
 Grand Master
Joined: 28 Feb 2003 Posts: 1311 Location: USA
|
Just because a queue is defined as a "non-persistant" queue does not make the messages so. An application can send a persistant (or non-persistant) message to any queue.
How did you establish that the messages were/are actually non-persistant? |
|
Back to top |
|
 |
mvic |
Posted: Mon Apr 03, 2006 9:58 am Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
EddieA wrote: |
it is the persistence that a message will get, if the putting application does not explicitly set the persistence. |
Well... The app must set MD.Persistence to MQPER_PERSISTENCE_AS_Q_DEF in order for the queue definition to be used. Therefore a conscious decision is necessary by the app to delegate to the queue definition. This is not very different from what you said, but needs saying I think. |
|
Back to top |
|
 |
atoms |
Posted: Mon Apr 03, 2006 11:44 am Post subject: |
|
|
Apprentice
Joined: 10 Jun 2005 Posts: 27
|
Well, what I referred to as "persistance" was the property of the queue as it can be seen if you right-click the queue on a windows machine ("default persistance").
But if I understand correctly what you all say, this does NOT mean that a message on this queue is necessarily persistant. I wasn't aware of that, thank you all for this "eye-opener"! |
|
Back to top |
|
 |
wschutz |
Posted: Mon Apr 03, 2006 11:59 am Post subject: |
|
|
 Jedi Knight
Joined: 02 Jun 2005 Posts: 3316 Location: IBM (retired)
|
Yes, its the "default" persistence, meaning it is the value used if the application doesn't specify a persistence. Just like "default priority",
"default share option", and "default bind type". _________________ -wayne |
|
Back to top |
|
 |
mvic |
Posted: Mon Apr 03, 2006 12:05 pm Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
wschutz wrote: |
it is the value used if the application doesn't specify a persistence. |
(Am I being overly pedantic?)... it's not really a default in the normal usage of the word ... the queue definition is consulted if the application chooses to delegate by setting MD.Persistence = MQPER_PERSISTENCE_AS_Q_DEF. |
|
Back to top |
|
 |
jefflowrey |
Posted: Mon Apr 03, 2006 12:14 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
|
Back to top |
|
 |
wschutz |
Posted: Mon Apr 03, 2006 12:14 pm Post subject: |
|
|
 Jedi Knight
Joined: 02 Jun 2005 Posts: 3316 Location: IBM (retired)
|
mvic wrote: |
(Am I being overly pedantic?)... |
Perhaps you are .... You initialize the MQMD to the "default values" and then choose not to set the Persistence element, thus taking the default  _________________ -wayne |
|
Back to top |
|
 |
mvic |
Posted: Mon Apr 03, 2006 12:29 pm Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
jefflowrey wrote: |
Well, it is the default value of MQMD.Persistance.. |
Oops, you're right
(By the way, it's Persistence)  |
|
Back to top |
|
 |
|