Triggered task - don't wait for API response

I have a pipeline that is acting as a “driver” pipeline to kick off other pipelines. I would like to kick off the children pipelines using a triggered task and a REST API call in the parent pipeline. I can get this to work, but I’m noticing that the REST API snap in the parent pipeline is waiting for the child pipeline to finish before moving on. I don’t want want it to wait. I just want it to make the REST API call and move on. How can I accomplish this?

For more of an asynchronous behavior, design your child pipeline so that it sends back a response to the parent (unlinked output) sooner.

2 Likes

Hi @dwhansen-cbg,

When the child pipeline finishes its execution, do you need some output to be passed onto the parent pipeline once the execution is completed?
If you don’t, then the REST API snap will have a document on its output view as soon as it receives a document from the executing child pipeline. So, yes, as @christwr points out, you could have the child pipeline send a document from an unlinked output view of, say, a Mapper Snap or a JSON Generator Snap. That way the REST API Snap receives its document and carries on on its merry way, and the child pipeline continues its execution on its own, up to the time when it completes.

Hope this is useful to you.

BR,
Dimitri

1 Like

Thanks @christwr and @dimitri.hristovski! I think that will work for me. I don’t care what happens to the child pipeline (at least the parent doesn’t need to know) as long is it kicks off. Thanks!