Author |
Message
|
euphoria |
Posted: Mon Dec 11, 2006 12:13 pm Post subject: leave uncomitted messages on queue ? |
|
|
Acolyte
Joined: 08 Feb 2004 Posts: 51
|
Is there any simple way to leave uncomitted messages on the queue. I wanted to work with the recovery and try some stuff. Any pointers would be helpful ... (I dont have access to WAS to try transactional stuff)
OS unix ,MQ 5.3 and 6
Thanks |
|
Back to top |
|
 |
jefflowrey |
Posted: Mon Dec 11, 2006 12:23 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Quit your program without committing them...
Depending on the language, this may require knowing whether to issue MQDISC or not. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
mvic |
Posted: Mon Dec 11, 2006 12:49 pm Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
jefflowrey wrote: |
Quit your program without committing them...
Depending on the language, this may require knowing whether to issue MQDISC or not. |
To be sure your messages are backed-out, call MQBACK. |
|
Back to top |
|
 |
jefflowrey |
Posted: Mon Dec 11, 2006 12:56 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Euphoria doesn't want messages backed out.
Euphoria wants uncommitted messages on the queue. That means NOT backed out. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
mvic |
Posted: Mon Dec 11, 2006 1:06 pm Post subject: |
|
|
 Jedi
Joined: 09 Mar 2004 Posts: 2080
|
jefflowrey wrote: |
wants uncommitted messages on the queue. That means NOT backed out. |
I guess I don't understand the question then.
I thought "Is there any simple way to leave uncomitted messages on the queue." meant "is there any way to rollback my MQGETs".
Also, I thought your answer "Quit your program without committing them..." confirmed this interpretation. |
|
Back to top |
|
 |
jefflowrey |
Posted: Mon Dec 11, 2006 1:12 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
I read Euphoria's question as "How do I set up a test environment so I experiment with resolving uncommited messages, to mimic when a program fails badly".
Quote: |
I wanted to work with the recovery and try some stuff |
_________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
euphoria |
Posted: Mon Dec 11, 2006 1:18 pm Post subject: |
|
|
Acolyte
Joined: 08 Feb 2004 Posts: 51
|
Thanks for your replys ... I wanted uncomitted messages . being a non-programmer, i tried to get a way around the program and got into windows and used amqapi. In advanced mode i tried the sync point options and started transactions and killed the utility in the middle. did try few things with it, no luck yet. if all options exhaust with amqapi, will get with few lines of code and try again. |
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Dec 11, 2006 4:49 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Try something bizarre:
XA transaction mode put a message to the queue.
Issue an XAPrepareCommit
Disconnect from the QM without sending an XACommit or an XARollback. (How about sending an XAClose ?)... Of course this is against XA rules but then....
The message is on the queue in a non gettable state. Use rsvmqtrn to resolve the aborted transaction...
Enjoy  _________________ MQ & Broker admin |
|
Back to top |
|
 |
|