06-01-2022 05:00 AM
Is there a way/expression to capture pipeline invocation type (i.e. Scheduled Task, Triggered Task, Manual).
Solved! Go to Solution.
06-03-2022 12:21 AM
Hey @nishant.k9,
There’s a way to capture the invoker type by using the elastic api. Basically we’re going to gather all executions of that particular pipeline, and separate only the last one (that’s the actual execution that’s going to trigger the elastic request). In the response there’s a field that points to the invoker type. Unfortunately there’s no parameter to separate the last execution, at least I don’t know one, that’s why I added one more snap with an expression that filters out the information we need.
You’ll need a basic auth account for the snaplogic elastic request. Note that this will work only upon execution, and if you want to validate and test, you’ll need to use Record Replay.
CaptureInvoker_2022_06_03.slp (4.2 KB)
Regards
Bojan
06-02-2022 05:29 AM
Hi @nishant.k9 ,
Yes there is. You need to make use of the snaplogic list snap. It will get the metadata from snaplogic about pipelines/accounts/tasks, etc
So in this case:
Regards
Jens
06-02-2022 10:41 PM
@JensDeveloper
Thank you for the response, but i have bit different ask.
Like, consider there is a pipeline which is scheduled at some frequency. Now this pipeline can be executed in two way : one is manually by user and other is automatically by scheduler. So I want to capture specific runtime information whether the execution was manual or scheduled, for audit purpose.
06-03-2022 12:21 AM
Hey @nishant.k9,
There’s a way to capture the invoker type by using the elastic api. Basically we’re going to gather all executions of that particular pipeline, and separate only the last one (that’s the actual execution that’s going to trigger the elastic request). In the response there’s a field that points to the invoker type. Unfortunately there’s no parameter to separate the last execution, at least I don’t know one, that’s why I added one more snap with an expression that filters out the information we need.
You’ll need a basic auth account for the snaplogic elastic request. Note that this will work only upon execution, and if you want to validate and test, you’ll need to use Record Replay.
CaptureInvoker_2022_06_03.slp (4.2 KB)
Regards
Bojan
06-03-2022 05:38 AM
@bojanvelevski
Thank you… it somehow solved my problem