Fix the issue with multiple agent call
This patch fixes the issue related to execution of the same execution plan on multiple VMs. The root cause was agent handling code which overwrites template with execution plan. Now template is deep copied before execution plan creation. Thanks to Stan to help to fix that. Change-Id: I1d101ab155c46986ac4eed0e53beed7c8df1b569 Closes-Bug: #1335929
This commit is contained in:
@@ -13,6 +13,7 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
import copy
|
||||||
import datetime
|
import datetime
|
||||||
import os
|
import os
|
||||||
import types
|
import types
|
||||||
@@ -136,6 +137,7 @@ class Agent(murano_object.MuranoObject):
|
|||||||
}
|
}
|
||||||
|
|
||||||
def buildExecutionPlan(self, template, resources):
|
def buildExecutionPlan(self, template, resources):
|
||||||
|
template = copy.deepcopy(template)
|
||||||
if not isinstance(template, types.DictionaryType):
|
if not isinstance(template, types.DictionaryType):
|
||||||
raise ValueError('Incorrect execution plan ')
|
raise ValueError('Incorrect execution plan ')
|
||||||
format_version = template.get('FormatVersion')
|
format_version = template.get('FormatVersion')
|
||||||
|
Reference in New Issue
Block a user