So my current web service seems to be running into a weird problem.
I have a tRestRequest --> tJavaRow ( read some data from the request ) --> tMSSqlConnection --> tMSSQLOutput (Save the data from request) --> tMSSqlLastInsertID .
I save this info from tMSSqlLastInsertedID in a context variable which is used at a later stage.
I have seen a couple of instances where requests reaching almost simultaneously to the service and the tMSSqlLastInsertID context variable gets overwritten before it gets written in other DB tables...
What is the best way to prevent the context variable being overwritten when multiple parallel requests come in?
Hmmm this is interesting. Can you make a change and test it? Replace your context variables and use the globalMap. In the past when there were issues with thread safety in the ESB, I would go to the globalMap. Does it work now? If so, this needs to be highlighted on the Talend Jira site with an example.
I faced the same problem again... the GlobalMap thing does not seem to work. I saw a completely different instance being assigned and used. Any thing else I can try will be appreciated.