[resolved] Running a subjob onsubjoberror OR onsubjobok without repeating twice?

One Star

[resolved] Running a subjob onsubjoberror OR onsubjobok without repeating twice?

I would like to be able to run a subjob after a component regardless if the component has succeded or failed.
Currently I use both a OnSubjobOk and a OnSubjobError from the component in question to the same subjob, like this:


The problem with this approach is that it looks messy. Given that there is not a "OnSubjobOk_OR_OnSubjobError" trigger, is there a workaround I can use to implement what I'de like?
I attempted a "run if" trigger, where the condition was true == true. This worked if the component in question was a subjob or component that had a "Die on child error" check box, if I left he check box unchecked. It however did not work for components lacking a "Die on child error" check box, such as tJava.
Regards,
Matthew Moisen

Accepted Solutions
Seventeen Stars

Re: [resolved] Running a subjob onsubjoberror OR onsubjobok without repeating twice?

Connect both triggers (OnSubjobOk and OnSubjobError) to a tJava(_2 and _3) (without any code).
Now connect from each tJava with OnComponentOk to your target component (e.g. the tRunJob).

All Replies
Seventeen Stars

Re: [resolved] Running a subjob onsubjoberror OR onsubjobok without repeating twice?

Connect both triggers (OnSubjobOk and OnSubjobError) to a tJava(_2 and _3) (without any code).
Now connect from each tJava with OnComponentOk to your target component (e.g. the tRunJob).
One Star

Re: [resolved] Running a subjob onsubjoberror OR onsubjobok without repeating twice?

You may also using a "run if" trigger and set the condition to "true"

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

Definitive Guide to Data Quality

Create systems and workflow to manage clean data ingestion and data transformation.

Download