Reusable Job to be used Concurrently

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
Andal
Participant
Posts: 124
Joined: Thu Dec 02, 2004 6:24 am
Location: Bangalore, India

Reusable Job to be used Concurrently

Post by Andal »

We are having a reusable job (loads one hash file to another hash file) which will be commonly used in all jobs.

We had given a master sequence which will run all the jobs sequentially, so till now we dont have problem. But one of our customer wants to run the jobs concurrently.

In this situation we are getting the error,
"JobControl (fatal error from DSRunJob): Job control fatal error (-2)
(DSRunJob) Job <reusable jobname> is not in a runnable state".

I think two jobs are trying to access the reusable job at the same time, I had tried "Allow Multiple Instance" for the reusable job. But still I am getting the same error.

Is there any way to resolve this or can't we run these jobs concurrently?
Rgds
Anand
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Each instance of a multi-instance job must have a unique name. You are trying to concurrently run the same job with the same instance name.
Andal
Participant
Posts: 124
Joined: Thu Dec 02, 2004 6:24 am
Location: Bangalore, India

Post by Andal »

I had changed the name for each instance of the job, But we are having another job (reusable job) which is called from a routine.

we are calling it as DSAttachJob("<reusable job>", DSJ.ERRFATAL), whether this will create two instances, if it is called in two jobs at the same time or it will give error.
Rgds
Anand
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Without specifying an Invocation ID in the routine - yes, two calls at the same time will fail. Make sure you are attaching to "<resuable job>.<unique invocation id>".
-craig

"You can never have too many knives" -- Logan Nine Fingers
sun rays
Charter Member
Charter Member
Posts: 57
Joined: Wed Jun 08, 2005 3:35 pm
Location: Denver, CO

Post by sun rays »

Andal wrote:I had changed the name for each instance of the job, But we are having another job (reusable job) which is called from a routine.

we are calling it as DSAttachJob("<reusable job>", DSJ.ERRFATAL), whether this will create two instances, if it is called in two jobs at the same time or it will give error.
The property "allow multiple instances" does not automatically propagate through the heirarchy to the child job from a parent job. This property should be specified explicitly to each of the jobs that are being called.
ucf007
Charter Member
Charter Member
Posts: 18
Joined: Fri Feb 27, 2004 2:25 pm

Post by ucf007 »

You can use a multiple instance job, setting a different invocation ID in (one invocation ID for each call to the job) the sequencer ...
Andal
Participant
Posts: 124
Joined: Thu Dec 02, 2004 6:24 am
Location: Bangalore, India

Post by Andal »

Thanks for all, Now The jobs are running concurrently.
Rgds
Anand
Post Reply