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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Safus
Creator
Creator

Update Context params with MetaservletAPI updateTask does not work with Talend v8.0.1

This metaServletAPI call does not insert new context values to the already existing task.

{

 "actionName": "updateTask",

 "authPass": "XXXXXXX",

 "authUser": "XXXXXXXX",

 "context":{"varname1": "varvalue", "varname2": "varvalue2"},

 "taskId": 10,

 "timeout": 3600

}

I can see the timeout value being updated but not the context params. (No parsing problem ... )

I know that I can directly insert some rows in Database but for me it's the ugliest and most unrecommended solution.

Is it a new bug ? or the call is somehow wrong ?

Labels (2)
3 Replies
Anonymous
Not applicable

Hello

I look into the metaSevlet API documentation, the updateTask command allows customize value and make it enabled for context.

Go to check if it works with only one variable.

{

 "actionName": "updateTask",

 "authPass": "XXXXXXX",

 "authUser": "XXXXXXXX",

 "context":{"varname1": "varvalue"},

 "taskId": 10,

 "timeout": 3600

}

 

with 2 or more variables.

{

 "actionName": "updateTask",

 "authPass": "XXXXXXX",

 "authUser": "XXXXXXXX",

 "context":{"varname1": "varvalue";"varname2": "varvalue2"},

 "taskId": 10,

 "timeout": 3600

}

 

 

Regards

Shong

 

Safus
Creator
Creator
Author

Hello @Shicong Hong​ 

I have already tested with one value but it does not work.

But the endpoint can update a value of an existing context variable and it does not create a new variable.

Is is a bug or is it what it is was developed for ?

Is there a way to create a new custom context variable for a task ?

Anonymous
Not applicable

@safouane BEN MANSOUR​ , the context parameter here is used to pass a new value, rather than creating a new variable, the context variable must be defined in the job in studio.