Hi All
I need a help to pass Invocation ID at run time to a Sequence.
What i am trying to do?
I am triggering a SEQUENCE job (Multiple Instance) using Server Routine (TriggerRoutine). So that the SEQUENCE can trigger different jobs at the same time concurrently.
My Loop Design Approach:
GetJobsToRun --> StartLoop --> TriggerRoutine --> EndLoop
TriggerRoutine --> This will trigger a Sequence Job, which is a multiple instance in which i need to pass Invocation ID to this Sequence.
Say for example:
If i need to trigger the Sequence for the jobs J1,J2,J3. i wish the sequence to run like Seq.J1, Seq.J2, Seq.J3. So the it can be triggered almost(!) at the same time
Thanks in Adcance,
DS User
I need a help to pass Invocation ID at run time to a Sequenc
Moderators: chulett, rschirm, roy
So... what's your actual question?
Without knowing how your routine runs jobs, it's hard to provide specific advice. It seems like you know you just include the Invocation ID with a 'dot' after the job name when launching it. How exactly does 'GetJobsToRun' work? Seems to me the best approach would be for it to return a delimited list of invocation ids and then you tell the Loop stage to iterate through that list. A User Variables stage is where you would typically do that work and then pass the list from there to the Loop Start.
Without knowing how your routine runs jobs, it's hard to provide specific advice. It seems like you know you just include the Invocation ID with a 'dot' after the job name when launching it. How exactly does 'GetJobsToRun' work? Seems to me the best approach would be for it to return a delimited list of invocation ids and then you tell the Loop stage to iterate through that list. A User Variables stage is where you would typically do that work and then pass the list from there to the Loop Start.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
I amy Sorry, i may not explained properly.
Let me explain .
I will get the list of jobs names to run for the day in a file.
Ex:
J1
J2
J3
I created a job design in Sequence to trigger the above jobs.
Command Activity --> StartLoop --> TriggerRoutine --> EndLoop
Here, TriggerRoutine will always trigger a SEQUENCE job called "StartJob" which is a multiple instance job.
What StartJob will do?
RoutineActivity --> RunAJob --> RoutineActivity
RoutineActivity --> Make an entery in a table about the job start.
RunAJob (Multiple instance) --> Server Job; Code written in Job Control to trigger a job.
RoutineActivity --> Make an entery in a table about the job end.
Expectation:
Jobs J1, J2,J3 will be triggered by the master loop job one by one in each iteration.
Wish:
J1 need to start a seperate instance StarJob.J1
J2 need to start a seperate instance StarJob .J2
J3 need to start a seperate instance StarJob .J3
This is what i am trying to do.
Let me know to do this!
Let me know if it is not a good approach.
Thanks
DS User
Let me explain .
I will get the list of jobs names to run for the day in a file.
Ex:
J1
J2
J3
I created a job design in Sequence to trigger the above jobs.
Command Activity --> StartLoop --> TriggerRoutine --> EndLoop
Here, TriggerRoutine will always trigger a SEQUENCE job called "StartJob" which is a multiple instance job.
What StartJob will do?
RoutineActivity --> RunAJob --> RoutineActivity
RoutineActivity --> Make an entery in a table about the job start.
RunAJob (Multiple instance) --> Server Job; Code written in Job Control to trigger a job.
RoutineActivity --> Make an entery in a table about the job end.
Expectation:
Jobs J1, J2,J3 will be triggered by the master loop job one by one in each iteration.
Wish:
J1 need to start a seperate instance StarJob.J1
J2 need to start a seperate instance StarJob .J2
J3 need to start a seperate instance StarJob .J3
This is what i am trying to do.
Let me know to do this!
Let me know if it is not a good approach.
Thanks
DS User
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
You seem a little confused about how to invoke multi-instance jobs. "StartJob", for example, is a constant. Also, the invocation ID follows, rather than precedes the job name.
Best practice is to determine the sequence's invocation ID (probably in a routine activity) and pass that to the Job activities that run J1, J2 and J3.
Best practice is to determine the sequence's invocation ID (probably in a routine activity) and pass that to the Job activities that run J1, J2 and J3.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Hi Allray.wurlod wrote:You seem a little confused about how to invoke multi-instance jobs. "StartJob", for example, is a constant. Also, the invocation ID follows, rather than precedes the job name.
Best practice is to determine the sequence's invocation ID (probably in a routine activity) and pass that to the Job activities that run J1, J2 and J3.
Thanks for your guidance.
I got it and did it.
I will mark it as resolved.
Thanks a lot.
DS User