Allow using "fail" with a reason that will be shown in the WF execution state info

Registered by Moshe Elisha

This blueprint has been superseded. See the newer blueprint "Allow WF author to define meaningful message for fail transition" for updated plans.

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_vm_and_send_email:
  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_vm).result.id %>
      on-error:
        - send_error_email

    send_error_email:
      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
Completed by
Renat Akhmerov

Related branches

Sprints

Whiteboard

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.