More than one trigger (subjob dependencies)?

One Star

More than one trigger (subjob dependencies)?

Hello,

is it possible to run a Subjob only if two more Jobs ran sucessfully (more than one Job dependency). 
Something like that
Subjob D waits for finishing Subjob A and B
Subjob E waits for Subjob A and C
Subjob F has to wait for D and E
...
Is it possible to run a Subjob if at least one Job has finished:
Subjob C waits until Subjob A OR Subjob B has finished

Thanks
Talend DI Newbie

Re: More than one trigger (subjob dependencies)?

Hi Olbu,
A  ---onSubJobOk--- C
                            |
                         Runif     
                            |
                           B

Here ,  In subJob B , try to set globalMap variable and In Runif ,try to get value and check  it is not null.  
Note that You cannot have 2 onSubJobOk link on 1 Component. So you have to eliminate this limitation by using Runif link in second subjob.

I hope, it will help you.
Regards,
Amol
One Star

Re: More than one trigger (subjob dependencies)?

Hi Amol,
thanks, but I think that this couldn't work. C depends on a successful run of A and B. In your case Talend DI starts C also if only A would be ready.
But, yes. We could implement this with few "run if"-trigger. Today we would define a tPrejob wich defines a global variable (tSetGlobalVar)
Name:
"myTriggerCount"

Value:
new java.util.concurrent.atomic.AtomicInteger(0)

The last component of our A and B would have the following "run if"-trigger condition:

((java.util.concurrent.atomic.AtomicInteger) globalMap.get("myTriggerCount")).incrementAndGet()==2


, but we hoped that there would be some stages which support such scenarios by default. (Perhaps we also need to check the Status of the last component of A and B)
Thanks
Oliver

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

Why Companies Move to the Cloud: 7 Success Stories

Learn how and why companies are moving to the Cloud

Read Now