Using sensors to implement complex operations #6175
UqamProvencherRobert
started this conversation in
General
Replies: 1 comment 7 replies
-
you can also call the /executions api and get an execution ID, no? |
Beta Was this translation helpful? Give feedback.
7 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
If the current topic is not suited for this forum, please write me so and I'll remove it.
We are considering using St2 to automate something like a hundred workflows.
Most of these wf would be triggered by an http request telling us something happened in an application.
But with the basic understanding I have of St2, it seems that an http request would be caught by a sensor.
Like the echo_flask_app sensor in the Examples pack.
The answer to the request is sent by the sensor. Not the following action(s) defined by a rule.
So if the answers given to the requests need informations from the operations we implement,
we would have to code all our things in sensors and not use trigers-rules-workflows-actions.
The most basic example is if something goes wrong during the execution of an operation, we would want to answer a
500 Internal Server Error to the request. How to do that if our code is in actions ?
So, finally, I'd like to ask these questions :
In the St2 paradigm/philosophy is it ok to code everything in sensors, even complex operations, not using rules-actions... ?
Does that defeat the purpose of using St2 ?
Is there a way to use the whole sensor-trigger-rule-workflow-actions sequence to receive an http request with a sensor and at the last action answer this request ?
Thanks for your time!
Beta Was this translation helpful? Give feedback.
All reactions