Fail the baremetal workflows when sending a "FAILED" message
When Mistral workflows execute a second workflow (a sub-workflow
execution), the parent workflow can't easily determine if sub-workflow
failed. This is because the failure is communicated via a Zaqar message
only and when a workflow ends with a successful Zaqar message it appears
have been successful. This problem surfaces because parent workflows
should have an "on-error" attribute but it is never called, as the
workflow doesn't error.
This change marks the workflow as failed if the message has the status
"FAILED". Now when a sub-workflow fails, the task that called it should
have the on-error triggered. Previously it would always go to
on-success.
Reviewed: https:/ /review. openstack. org/418423 /git.openstack. org/cgit/ openstack/ tripleo- common/ commit/ ?id=c7b01eba55e 5d133ccc19451cf 4727170a5dbdd0
Committed: https:/
Submitter: Jenkins
Branch: master
commit c7b01eba55e5d13 3ccc19451cf4727 170a5dbdd0
Author: Dougal Matthews <email address hidden>
Date: Tue Jan 10 14:35:36 2017 +0000
Fail the baremetal workflows when sending a "FAILED" message
When Mistral workflows execute a second workflow (a sub-workflow
execution), the parent workflow can't easily determine if sub-workflow
failed. This is because the failure is communicated via a Zaqar message
only and when a workflow ends with a successful Zaqar message it appears
have been successful. This problem surfaces because parent workflows
should have an "on-error" attribute but it is never called, as the
workflow doesn't error.
This change marks the workflow as failed if the message has the status
"FAILED". Now when a sub-workflow fails, the task that called it should
have the on-error triggered. Previously it would always go to
on-success.
Closes-Bug: #1651704 44753649b59b7c1 d7c4b61fa8e
Change-Id: I60444ec692351c