Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Confusion on Backout MQ

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Java & MQSeries
View previous topic :: :: View next topic  
Author Message
srinut123

New User


Joined: 11 Oct 2005
Posts: 62
Location: India

PostPosted: Thu May 31, 2012 1:57 pm    Post subject: Confusion on Backout MQ
Reply with quote

Hi,
I've some confusion on Backout MQ. Can anyone please clarify this?

I've a trigger MQ with backout threshold limit set to '3'. If the trigger program fails for some reason and doesn't consume the message, the transaction is getting retriggered. I thought the retriggering happens for "3" times and then then message will be moved to Backout queue automatically but that is not happening. The transaction getting triggered more than "3" times and going into loop, infact until I removed the message from trigger MQ the MQ has been triggering the transaction.

Is it the application program responsibility to move the message to backout queue or it is moved automatically?
If application program's responsibility, whats the purpose of delcaring backout queue name in Trigger MQ definition?

If program abends as soon it enters, program can't handle the backout count even, how to stop looping in this case?

Thanks
Sri
Back to top
View user's profile Send private message

Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1534
Location: Andromeda Galaxy

PostPosted: Thu May 31, 2012 2:07 pm    Post subject:
Reply with quote

What is Backout queue ? Are you talking about DEAD LETTER QUEUE?

What is your triggger type ??
Back to top
View user's profile Send private message
srinut123

New User


Joined: 11 Oct 2005
Posts: 62
Location: India

PostPosted: Thu May 31, 2012 2:33 pm    Post subject: Confusion on Backout MQ
Reply with quote

No, I dont mean "DEAD LETTER QUEUE". Trigger type is "F". I'm talking about the "Backout requeue name" mentioned in the queue properties shown below.

More: -
Queue name . . . . . . . . : TEST.QUEUE
Disposition . . . . . . . . : QMGR VST1

Backout Reporting
Backout threshold . . . : 3 0 - 999999999
Harden backout counter . : N Y=Yes, N=No
Backout requeue name . . : TEST.QUEUE.BACKOUT

Retention interval . . . . : 999999999 0 - 999999999 hours

Monitoring . . . . . . . . : Q Q=Qmgr, L=Low, M=Medium, H=High, O=Off
Accounting . . . . . . . . : Q E=Enabled, D=Disabled, Q=Qmgr
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1534
Location: Andromeda Galaxy

PostPosted: Thu May 31, 2012 3:13 pm    Post subject:
Reply with quote

One thing is that trigger type 'F' (FIRST) could cause an infinite loop

Because

The program which executes MQ ( I assume you do a MQGET ) fails due to some reason and you rollback the operation and hence what happens is that the message which was got back writes again to you inputqueue

As it is first it would trigger you program again and again

Try changing the trigger type to every ( It would resolve you infinite loop )
Back to top
View user's profile Send private message
Garry Carroll

Active Member


Joined: 08 May 2006
Posts: 992
Location: Dublin, Ireland / Edinburgh, Scotland

PostPosted: Fri Jun 01, 2012 2:32 pm    Post subject:
Reply with quote

Quote:
If program abends as soon it enters, program can't handle the backout count even, how to stop looping in this case?


If the program abends as soon as it enters, it isn't getting as far as the MQGET so the backout count doesn't get incremented. This would explain multiple triggers and a failure to put the message on the backout requeue queue after 3 triggerings.

In this case the program needs to be fixed so it can at least get as far as the MQGET and the backout count checks.

Garry.
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1534
Location: Andromeda Galaxy

PostPosted: Thu Jun 14, 2012 12:34 am    Post subject:
Reply with quote

I was wrong earlier

The Trigger type FIRST has nothing to do with looping but since the backout set up was not done properLy you might face looping

Also in Mq v6 I am not sure if you can acieve backout automatically in this or higher version

What you might need to check for is when your program fails after getting from trigger queue and when Abend you might issue a syncpoint rollback so as said earlier the message got from the queue is Fed back to input queue so your program executes again and again

So this what you might need to do


In your program after MQGET check for backout count and threshold count

Set the threshold count as 2 in your get para

so you need to check in get para if backout count > threshold

When yes the record which was go needs to put to error queue and do a execute cics syncpoint

So for error scenarios the failed record will be written to error queue and on commit (syncpoint) your backout count initializes to 0

Hence ensuring successful backout and no looping occurs ,

And ensure your trigger type is F

This is concluded after sever test runs

This was much simpler for me

There might be a much simpler solution if that could be done at the time of trigger definition

Not pretty sure

I know I am replying pretty late on this though ( If you are still figuring out it might help or it will help others ) icon_smile.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Java & MQSeries All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Confusion while passing data to a cal... amitc23 COBOL Programming 5 Mon Mar 07, 2016 12:36 pm
No new posts SuperC comparison confusion Ashish.Srivastava.123 TSO/ISPF 1 Tue Aug 12, 2014 4:21 am
No new posts Batch Backout error aprocon IMS DB/DC 9 Fri Jan 31, 2014 11:38 pm
No new posts Massive DFS968I backout messages Hooman24 IMS DB/DC 2 Sun Jan 26, 2014 8:53 pm
No new posts I/O Charge Confusion dick scherrer All Other Mainframe Topics 8 Mon Jun 10, 2013 7:32 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us