cancel
Showing results for 
Search instead for 
Did you mean: 

Remote execution of long-running services question...

wolpert
Champ in-the-making
Champ in-the-making
Trying to figure out the best way to implement a task that calls a long-running remote service and then stops flow execution until its notified for completion without tying up the running computational thread. Would it make sense to have the remote service started using the "Java Service Task" (which we implement, of course), then the next task in the flow being the "Java Receive Task" which we would call in a programmatic fashion hours later? So the thread that initially ran the Java Service Task would be completed when the Java Receive Task was initially executed, and the flow itself would continue once the received task was signaled?

Just making sure I got that correct, and checking to see if there was another way to do this that would be better.
1 REPLY 1

jbarrez
Star Contributor
Star Contributor
That is indeed a good analysis. One extra thing: you will need the executionId to call back the process once the lon computation is done. An executionListener can also be used for this purpose (ie sending the executionId to the external system for later callback).