From 1e13e461cd4e5a1187cd8182ec74e8a5eb576e59 Mon Sep 17 00:00:00 2001 From: James Slagle Date: Fri, 14 Sep 2018 17:01:26 -0400 Subject: [PATCH] Handle non-existant plan when getting deployment status Instead of failing the workflow when requesting the deployment status of a non-existant plan, return a useful message instead. Change-Id: Ic0333c0726b16d284a7cc54bc68e16ea1c9ebc4d Partial-Bug: #1792637 --- .../notes/handle-no-deployment-status-a70a4b950171afbe.yaml | 5 +++++ workbooks/deployment.yaml | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 releasenotes/notes/handle-no-deployment-status-a70a4b950171afbe.yaml diff --git a/releasenotes/notes/handle-no-deployment-status-a70a4b950171afbe.yaml b/releasenotes/notes/handle-no-deployment-status-a70a4b950171afbe.yaml new file mode 100644 index 000000000..44b3b71eb --- /dev/null +++ b/releasenotes/notes/handle-no-deployment-status-a70a4b950171afbe.yaml @@ -0,0 +1,5 @@ +--- +fixes: + - The tripleo.deployment.v1.get_deployment_status workflow will no longer + error when requesting the deployment status for a non-existant plan. A + message is sent in the output instead of failing the workflow. diff --git a/workbooks/deployment.yaml b/workbooks/deployment.yaml index 28375cd9c..a2ca2b76c 100644 --- a/workbooks/deployment.yaml +++ b/workbooks/deployment.yaml @@ -697,8 +697,8 @@ workflows: deployment_status: <% yaml_parse(task().result.last()) %> on-complete: send_message publish-on-error: - status: FAILED - message: <% task().result %> + message: No deployment status found for plan <% $.plan %> + deployment_status: "" send_message: workflow: tripleo.messaging.v1.send