Open lakshmi-kannan opened 6 years ago
This is not a breaking issue any more, or at least, removing the callback
from executions will not remove any useful functionality.
callback
was only present to support mistral_v2 callbacks. The logic that actually used the callback was in post_run
and was removed when the mistral-specific st2resultstracker
was ripped out in #5108 here:
https://github.com/StackStorm/st2/pull/5108/files#diff-d7613a0fbf36747a29378082cec19dcaab464b67582aaa72ced86a778b65cb18L231-L234
If a runner needs a callback
param, it will need to implement that itself as the logic was removed in #5108. So, these are the remaining callback bits that should be removed:
st2common.callback
module (containing the AsyncActionExecutionCallbackHandler
which was only ever used with mistral; its abstract callback
method is no longer called anywhere).st2common/st2common/services/executions.py
:
https://github.com/StackStorm/st2/blob/8ac4c6fdd66eeae9468faf523da71acbb708432f/st2common/st2common/services/executions.py#L268callback
attribute on runner/liveaction/execution:
LiveActionDB
: https://github.com/StackStorm/st2/blob/2005126b733d474bf9626f47b3f78d1fe5ff0227/st2common/st2common/models/db/liveaction.py#L71-L74LiveActionAPI
:
https://github.com/StackStorm/st2/blob/0604a16163ce3a90c9d655700da249d7cffc6915/st2common/st2common/models/api/action.py#L421 https://github.com/StackStorm/st2/blob/0604a16163ce3a90c9d655700da249d7cffc6915/st2common/st2common/models/api/action.py#L477 https://github.com/StackStorm/st2/blob/0604a16163ce3a90c9d655700da249d7cffc6915/st2common/st2common/models/api/action.py#L493LIVEACTION_ATTRIBUTES
: https://github.com/StackStorm/st2/blob/8ac4c6fdd66eeae9468faf523da71acbb708432f/st2common/st2common/services/executions.py#L72st2common.runners.utils.invoke_post_run
func: https://github.com/StackStorm/st2/blob/8496bb2407b969f0937431992172b98b545f6756/st2common/st2common/runners/utils.py#L241st2actions.container.base.RunnerContainer._get_runner
: https://github.com/StackStorm/st2/blob/2005126b733d474bf9626f47b3f78d1fe5ff0227/st2actions/st2actions/container/base.py#L463openapi.yaml.j2
: https://github.com/StackStorm/st2/blob/710137f6ed39ae9ab3768284d2b11e5d2fc4f8a8/st2common/st2common/openapi.yaml.j2#L5351-L5352openapi.yaml
: https://github.com/StackStorm/st2/blob/710137f6ed39ae9ab3768284d2b11e5d2fc4f8a8/st2common/st2common/openapi.yaml#L5355-L5356st2tests/st2tests/fixtures
contrib/chatops/tests/fixtures
and st2client/tests/fixtures
st2actions/tests/unit/test_executions.py
contrib/runners/local_runner/tests/integration/test_localrunner.py
contrib/runners/noop_runner/tests/unit/test_nooprunner.py
contrib/core/tests/test_action_sendmail.py
st2client/tests/unit/test_formatters.py
When grepping through the code, the callback
param that needs to be removed is not related to the callbacks
in the transport (rabbitmq) or coordination (redis) related code.
The only question is if we need to do any migrations when we drop the field from the DB. I believe the answer is no.
+1 for the cleanup!
Thanks for contributing to this issue. As it has been 90 days since the last activity, we are automatically marking is as stale. If this issue is not relevant or applicable anymore (problem has been fixed in a new version or similar), please close the issue or let us know so we can close it. On the contrary, if the issue is still relevant, there is nothing you need to do, but if you have any additional details or context which would help us when working on this issue, please include it as a comment to this issue.