Page 1 of 1

Sequencer(server edition)

Posted: Mon Sep 19, 2005 12:17 am
by dslearner
Hi,

Please tell me any one know

Actually I am using Sequencer job, in that one DS Job depends on two DS Jobs. First I took the two job activities and one sequencer (All Mode) and finally one job Activity. Here I am using the routine activity for getting the individual job warnings and fatal error. Routine activity is call to each DS Job.
I have specified trigger condition for success (Job Status <>3) and failed (failed) for each DS job activity. When the individual DS job was aborted then routine activity written log file in corresponding directory. When the individual DS Job had finished with see log that time routine activity not written any log file.
After that I had written trigger condition at failed option as (DS Jobstatus = 2 or DS Jobstatus = 2). Routine activity was not performing any thing, when job was aborted or finished (see log).

I need the Log file when job is aborted or finished (see log). Please tell any one.

Posted: Mon Sep 19, 2005 1:24 am
by richdhan
Hi DSLearner,

For two job activities success triggers use the following condition

JobActivityName.$JobStatus= 1 or JobActivityName.$JobStatus= 2
(Job is finished or finished with warnings)

Use the Unconditional Trigger for the routine activites so that the log file is written both for success and failure

HTH
--Rich

Posted: Mon Sep 19, 2005 1:33 am
by ray.wurlod
There are a few possibilities along these lines.

For example you can have a Custom condition encompassing both success and warnings, like Rich suggested, on each Job Activity.

Another approach is to have a Failed trigger and and Otherwise trigger (this has the benefit of colouring your Failed trigger red).

Posted: Mon Sep 19, 2005 1:43 am
by richdhan
Hi Ray,

The log file needs to generated for both success and failure.

With Otherwise Trigger it will be generated for only one condition.

Pls Clarify.

Thanks
--Rich

Posted: Mon Sep 19, 2005 4:43 am
by dslearner
Hi Rich,

Thanks for ur help ,I gave above condition,but when the job was aborted that time routine does not written any log file.
i tried JobActivityName.$JobStatus= 1 or JobActivityName.$JobStatus= 2 Or JobActivityName.$JobStatus <>3,This time also not written any log file.
I gave Otherwise Trigger condition also ,But not written any log file.

Please tell me any other option.

Posted: Mon Sep 19, 2005 4:31 pm
by ray.wurlod
If there are two triggers, Otherwise and Failure, you have two branches. On the non-Failure branch you could use a Nested Condition activity to decide whether to log anything based on the job status.

Or you could have four triggers; one OK, two Warning, one Otherwise. The OK and one warning run into an Any sequencer then on to further processing. The other warning and Otherwise run into an Any sequencer then on to logging.

Lots of other possibilities.

Posted: Mon Sep 19, 2005 11:27 pm
by dslearner
Hi Ray,

Thanks you are valuable help.

First two jobs activity had set the trigger conditions, success condition (Ok) Failure condition (Otherwise), In these case when job Aborted or finished (see log) then write into the log file in to a respect folder.

After two jobs success (Sequencer) then go to third job activity. This job activity has only one trigger condition as when third job activity should be written into log file when the job was aborted or finished (see log).

Please tell me, which trigger condition can I give there.

Posted: Mon Sep 19, 2005 11:54 pm
by rleishman
I am having a bit of trouble understanding the English translation of this problem, but now I think I have it.
You have two independent jobs with output links to a Sequencer. The output link of the Sequencer is to a Routine that writes a log file. You want the Routine to fire whenever there is a failure in either job.

You mention that the Sequencer is set to ALL instead of ANY. I think that ANY would be the correct setting in this case, as you want the routine to fire if ANY of the jobs fail. Combine this with triggers on the output links of the jobs so that they only fire on ABORT and you should get the desired result.

OR....

A better way to do this is as follows:
  • In the Job Sequence "Properties" window, check "Automatically handle activities that fail". This means that when any job aborts, the Sequence will (attempt to) abort.
  • Delete the Sequencer - you don't need it.
  • Drag in an Exception Handler activity, and create a link from it to the log routine.
  • If you want the Job Sequence to exit without error, that's all you need to do. If you want the job sequence to abort, link the Routine to a Terminator Activity.
Now, when anything in the Job Sequence fails you have automated exception handling. :)