Log CDM structure before+after executing strategy

In this changeset, I added debug logs to dump the cluster data model
copy structure (as XML) before and after the execution of the strategy.

By doing so, we can see the cluster data model structure that is
expected after the execution of the corresponding action plan.

Change-Id: I81c23e148a78d9b176154f7620087a322a5bce28
This commit is contained in:
Vincent Françoise
2016-09-12 17:04:05 +02:00
parent 0a0f482f2d
commit fbd9411fd9
6 changed files with 20 additions and 1 deletions

View File

@@ -363,7 +363,7 @@ class WorkloadStabilization(base.WorkloadStabilizationBaseStrategy):
def create_migration_instance(self, mig_instance, mig_source_node,
mig_destination_node):
"""Create migration VM """
"""Create migration VM"""
if self.compute_model.migrate_instance(
mig_instance, mig_source_node, mig_destination_node):
self.add_migration(mig_instance.uuid, 'live',
@@ -437,3 +437,5 @@ class WorkloadStabilization(base.WorkloadStabilizationBaseStrategy):
This can be used to compute the global efficacy
"""
self.fill_solution()
LOG.debug(self.compute_model.to_string())