Two Stars

Job Duration / Alert

How do I trigger an email or Alert when a job runs beyond the expected run time.
EX: Say a job takes 5 min to complete usually. But when it exceeds 5 mins , can an alert be sent even before the job ends ?
I tried the tchronometerstart and tchronometerstop, but they give me the duration after the subjob/job ends.
Thanks,

1 REPLY
Seventeen Stars

Re: Job Duration / Alert

The only way to do this is running another in depended job which checks the duration of the worker job by e.g. logs or AMC tables or similar.
I would never try to check this within the job itself because the job could have an jvm error like MemoryErrors and in this case it would be impossible to do anything.
If you prefer the build-in methods from Talend I would suggest you make your self familiar with the AMC feature or you checkout the component suite tJobInstance* components which allows a lot more e.g. dead detection and so on.
http://www.talendforge.org/exchange/index.php?eid=1316&product=tos&action=view&nav=1,1,1
You could check this way all jobs for duration limits or any other key figures like number processed rows or work-items and so on.