From 7f630388eb891a893818ca424576c17447868c90 Mon Sep 17 00:00:00 2001 From: tina Date: Mon, 6 Jan 2020 14:21:46 -0500 Subject: [PATCH] Merge pull request #618 from lfu/automate_timeout_orchestration_service_1781353 Use automate timeout when execution_ttl is not set for an orchestration service (cherry picked from commit 73cf178d5f59d72a6ec87dcaa103a9f7a3f37d67) https://bugzilla.redhat.com/show_bug.cgi?id=1794752 --- .../StateMachines/Methods.class/__methods__/provision.rb | 1 + .../StateMachines/Methods.class/__methods__/reconfigure.rb | 1 + .../StateMachines/Methods.class/__methods__/provision_spec.rb | 1 + 3 files changed, 3 insertions(+) diff --git a/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision.rb b/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision.rb index bec8cb898..26093b19b 100644 --- a/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision.rb +++ b/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision.rb @@ -17,6 +17,7 @@ def main task = @handle.root["service_template_provision_task"] service = task.destination + service.set_automate_timeout(@handle.field_timeout, 'provision') begin stack = service.deploy_orchestration_stack diff --git a/content/automate/ManageIQ/Cloud/Orchestration/Reconfiguration/StateMachines/Methods.class/__methods__/reconfigure.rb b/content/automate/ManageIQ/Cloud/Orchestration/Reconfiguration/StateMachines/Methods.class/__methods__/reconfigure.rb index 6852a4f7b..11cd987e3 100644 --- a/content/automate/ManageIQ/Cloud/Orchestration/Reconfiguration/StateMachines/Methods.class/__methods__/reconfigure.rb +++ b/content/automate/ManageIQ/Cloud/Orchestration/Reconfiguration/StateMachines/Methods.class/__methods__/reconfigure.rb @@ -6,6 +6,7 @@ task = $evm.root["service_reconfigure_task"] service = task.source +service.set_automate_timeout(@handle.field_timeout, 'reconfigure') begin service.update_orchestration_stack diff --git a/spec/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision_spec.rb b/spec/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision_spec.rb index 58ee333b6..afc6e0e3b 100644 --- a/spec/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision_spec.rb +++ b/spec/content/automate/ManageIQ/Cloud/Orchestration/Provisioning/StateMachines/Methods.class/__methods__/provision_spec.rb @@ -34,6 +34,7 @@ current_object = Spec::Support::MiqAeMockObject.new current_object.parent = root_object service.object = current_object + allow(service).to receive(:field_timeout).and_return(8) end end