Talend: Job & Context

Mentari Enggar Rizki
4 min readDec 20, 2022

--

How to make Job & Context in Talend

1. Make a Job

What is a Job in Talend?

A Talend Job allows you to access and use the Talend components to design technical processes to read, transform, or write data (Talend, 2022).

Step-by-step

In the Repository menu (left tab), right-click on “Job Design” and then select create a job. I usually classify the jobs within a group so I made a folder first.

Create job option menu

Then, start inserting the job’s component by selecting it from the Pallete menu. For further information on these components, we can read from this list.

Pallete menu to search for a component

For example, I choose tRest component because I want to pull the auth data from HTTPSRequest. Then drop in the component inside the design field.

Then, we can setting for the component by double-clicking it until the configuration menu shown. We can configure its job, context, component, and run it to test.

2. Make Context

What is Context in Talend?

There are 3 ways “Context” is used in Talend:

  • Context variable: A variable which can be set either at compile time or runtime. It can be changed and allows variables which would otherwise be hardcoded to be more dynamic.
  • Context: The environment or category of the value held by the context variable. Most of the time Contexts are DEV, TEST, PROD, UAT, etc. This allows you to set up one context variable and assign a different value per environment.
  • Context Group: A group of context variables which are packaged together for ease of use. Context Groups can be dragged and dropped into jobs so that you do not have to set up the same context variables in different jobs. They can also be updated (added to) in one location and then the changes can be distributed to the jobs that use those Context Groups.

Step-by-step make context variable

In the Repository menu (left tab), right-click on “Context” and then select “create context group”.

Create context option menu

Fill the Name field. It’s optional to fill the purpose & description field. The case I choose is creating API context variable that contains:

  • Name: It’ll be used as called variable in other component.
  • API url: The value we want to make context for.
Fill the 1st page of creating context setting

Because I use API that also has autorization endPoint, so I make in context environtment such as:

  • endPointAuth: endpoint’s url to earn the auth token.
  • endPointDash: general endpoint.
  • authorization: it’s the token.

Click finish.

Use the Context Inside a Job

We can try to implement context inside a job. For example, we want to earn the authentication data from an API.

First, double click the tRest component and then choose Context menu. Click context icon.

Check the existing variable and select the context we want to pull. Then click “OK”.

And then, the context environtment will automatically filled with context setting we’ve been created.

May this helpful!

References

Talend Open Studio for Big Data Getting Started Guide (no date) Welcome to talend help center. Available at: https://help.talend.com/r/en-US/8.0/studio-getting-started-guide-open-studio-for-big-data/creating-job (Accessed: December 20, 2022).

Talend components: Top 7 different categories of Talend Components (2022) EDUCBA. Available at: https://www.educba.com/talend-components/ (Accessed: December 20, 2022).

Thank you!

--

--

Mentari Enggar Rizki

System Architect, Data Engineering, & Business Enthusiast.