Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Discover how organizations are unlocking new revenue streams: Watch here
cancel
Showing results for 
Search instead for 
Did you mean: 
pthomas
Contributor III
Contributor III

Project level vars

I have a few values that persist across jobs... or at least their need does.  In Talend, how can I make a project level value that can be called by any job that needs it?

eg. bob = "some guid value based on a subscription"

I need bob's value every time I call an api to bob's api list.  And bob has a lot of apis!  If my subscription changes, then I have to update every flow where bob's guid value is used.  

 

 

 

Labels (4)
1 Solution

Accepted Solutions
quentin-vigne
Partner - Creator II
Partner - Creator II

I can confirm that context once created from the context category (on the left side of the designer) are available from any job.

Here is a screenshot (sorry if it's in french)

quentinvigne_0-1742994758324.png

 

This is below the job list. Create a context group and you can use everywhere in your projetct.

 

- Quentin.

 

View solution in original post

5 Replies
quentin-vigne
Partner - Creator II
Partner - Creator II

Hello @pthomas 

 

For that use I recommend the use of context variable ! On the left side of the Talend Designer, there is a category called "contexts" 

Create a new context with your needs.
For example a context_api with variable such has "url".

 

When needed just import the context from the context tab below the designer and call it in your components with the value context.context_api_url like this :

quentinvigne_0-1742982098007.png

 

- Quentin

pthomas
Contributor III
Contributor III
Author

Context vars seem to only exist within a job.  Is there anything that can be written once and used in many jobs?

quentin-vigne
Partner - Creator II
Partner - Creator II

I can confirm that context once created from the context category (on the left side of the designer) are available from any job.

Here is a screenshot (sorry if it's in french)

quentinvigne_0-1742994758324.png

 

This is below the job list. Create a context group and you can use everywhere in your projetct.

 

- Quentin.

 

pthomas
Contributor III
Contributor III
Author

Got it thanks.  I've seen context within a job but missed the left side folder.

So creating a context on the left, I can then add that to context each job in the "job context" and only have to change a value in 1 place.

quentin-vigne
Partner - Creator II
Partner - Creator II

Yes, exactly.

For example we use context for an API call to create a ticket if the job failed.

Since this API call is in every job we needed to add it to a context and if it change we only have to edit the context, all of the jobs will then use the new values of the context.

 

- Quentin