Sophisticated functions with MQSeries Plugin

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
manavkumarm
Participant
Posts: 11
Joined: Fri Sep 05, 2003 3:45 am
Location: India

Sophisticated functions with MQSeries Plugin

Post by manavkumarm »

Hi all,

I am trying to use an MQSeries Plugin stage to check the reason code while writing to a queue. If the reason code is Queue Full, I want the stage to sleep for some time and then attempt the write again.

Can anyone give me any pointers on how I can achieve this using the MQ stage itself, without being forced to switch to a UNIX script entirely for my MQ writing?

Thanks,
Manav
trobinson
Participant
Posts: 208
Joined: Thu Apr 11, 2002 6:02 am
Location: Saint Louis
Contact:

Post by trobinson »

You've got two problems;
MQ Series plug-in and looping/sleeping.

An enhancement request has been made to allow the capture of the MQ Series return codes in order to allow them to be interrogated in subsequent link constraints. Currently upon detecting any kind of return code, a MQ Series job will abort.
In theory you could try the PUT and when the queue is full the Reason Code 2053 would be returned. You could trap that in a subsequent link constraint and invoke a sleep routine for any amount of time and try the PUT again. How many tries before you give up one, two, a dozen? Looping through the stages would be nice but not possible out of the box.
Post Reply