Allow using "fail" with a reason that will be shown in the WF execution state info
Currently using "fail" will fail the workflow and the user will need to go over the different entities and flow and find why.
This BP will add the ability to fail the workflow and provide a message that will appear in the workflow execution state info.
For example:
---
version: '2.0'
create_
type: direct
input:
- vm_name
- image_id
- flavor_id
tasks:
create_vm:
action: nova.servers_create name=<% $.vm_name %> image=<% $.image_id %> flavor=<% $.flavor_id %>
publish:
vm_id: <% task(create_
on-error:
- send_error_email
send_
action: send_email to_addrs=['<email address hidden>'] body='Failed to create a VM'
on-complete:
- fail('Failed to create a VM with image <% $.image_id %>')
Blueprint information
- Status:
- Complete
- Approver:
- None
- Priority:
- Undefined
- Drafter:
- Moshe Elisha
- Direction:
- Needs approval
- Assignee:
- None
- Definition:
- Superseded
- Series goal:
- None
- Implementation:
- Unknown
- Milestone target:
- None
- Started by
- Completed by
- Renat Akhmerov