Sequence aborts without running all jobs

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
ronchi
Premium Member
Premium Member
Posts: 10
Joined: Sun Dec 07, 2008 6:07 pm
Location: Australia (Melbourne)

Sequence aborts without running all jobs

Post by ronchi »

The current design:
We have a "master" sequence that calls a dozen other sequences (After an initialisation job that sets the batchid, there are 6 independent "paths" through the sequence, with each path calling an "extract" and a "load" sequence).

Each job activity has an output link for Warning and Failure return codes, that pass control to a Sequencer then to a Notification and then a Terminator.
There is also an Exception Handler that links into this Sequencer, to trap abnormal errors.

The Terminator is set to "Abort without sending STOP requests" and "Wait for all jobs to finish first."

The problem:
2 of the 6 "extract" sequences abort. The remaining extracts run through to completion. The "master" sequence aborts. But none of the "load" sequences are started.

What we want/expected:
4 of the 6 "extract" sequences complete successfully. For these extracts, we want the "load" sequences to run, despite the other 2 "extracts" failing.
We also want an email notification that the "master sequence" did not complete successfully.

Can we please get some advice on how to make the sequence do what we want?

I hope the above description makes sense. Please let me know if you need further explanation or any other information.
Last edited by ronchi on Wed Feb 11, 2009 9:02 pm, edited 1 time in total.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Re: Sequence aborts without running all jobs

Post by chulett »

Hmmm... don't really have time to absorb all of this, but wanted to single this out at the moment:
ronchi wrote:The Terminator is set to "Abort without sending STOP requests" and "Wait for all jobs to finish first."
This means "Wait for all currently running jobs to finish first", not literally "all" jobs. It will not complete the Sequence and then do the abort, if that's what you're thinking it would do. Seemed that way from your subject line, hence the comment.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ronchi
Premium Member
Premium Member
Posts: 10
Joined: Sun Dec 07, 2008 6:07 pm
Location: Australia (Melbourne)

Post by ronchi »

Ah, thanks Craig.
Yes, I fell for the trap, and thought it meant it'd wait for all jobs to start and finish.

Something I forgot to mention: the sequence also has an Exception Handler that links into the error-handling Sequencer, to trap any unexpected problems (such as a job in the wrong state). I'll edit the original post.

The fix:
I removed the Terminator stage, and reran the sequence. The "load" sequences ran fine for the 4 working "extracts", and sent an email that the some "extract" jobs had failed.

The only loss was that the "master sequence" did not end with an abort status. This is only a minor inconvenience, because the email notification will alert the support team that there was a problem.
Post Reply