One Star

How to get the TAC job name from talend job

Hi,
We are using Talend Administrator Center (TAC) for scheduling Talend jobs. I would like to know how get the TAC job name inside talend job? I need this in order to know which TAC job is failed so that it can be included in notification email? using tAssetCatcher I am able to get the actual talend job name, but with that operation team is facing difficult to identify the associated TAC job name to look into the log.
Thanks.
4 REPLIES
Six Stars JR
Six Stars

Re: How to get the TAC job name from talend job

I am assuming you want to get the task name instead of the job name, correct? If yes, you can create a context variable in the job and override the value on the task in the TAC to the task's name. The job itself will never know how it has been started and therefore cannot know about the task name in the TAC.
One Star

Re: How to get the TAC job name from talend job

I actually need to know the TAC job name to notify the dev-ops teams that so and so job failed.
Example:
TAC Job Name: DELTA_RSS_DATA_INGESTION
Talend Job Name: ingestRssDeltaData
I want to know TAC job name with in "ingestRssDeltaData". I don't want to hard code job name in talend job context variables.
Six Stars JR
Six Stars

Re: How to get the TAC job name from talend job

No need to hard code the job name. Simply create a context variable in your job (e.g. tacTaskName) and leave it NULL. In the Job Conductor in the TAC you then select the job, click on "Context Parameters" at the bottom and override the value to the name of the task (DELTA_RSS_DATA_INGESTION). This runtime value will then be used in your job and you can access it via context.tacTaskName.
Fifteen Stars

Re: How to get the TAC job name from talend job

Or you could create a more generic solution using the Talend Metaservlet (https://help.talend.com/search/all?query=Talend+Administration+Center+MetaServlet+API&content-lang=e...).
Rilhia Solutions