diff options
| author | Michael Still <mikal@stillhq.com> | 2012-02-18 09:29:10 +1100 |
|---|---|---|
| committer | Michael Still <mikal@stillhq.com> | 2012-02-18 09:29:10 +1100 |
| commit | a0651f4b19f84fe926fd5c9bf81a2da059aa996d (patch) | |
| tree | b371234194453b698d57a79a23e49a9b7bb3c32e | |
| parent | 24716297334bccee029de62151bada216d896a3f (diff) | |
| download | nova-a0651f4b19f84fe926fd5c9bf81a2da059aa996d.tar.gz nova-a0651f4b19f84fe926fd5c9bf81a2da059aa996d.tar.xz nova-a0651f4b19f84fe926fd5c9bf81a2da059aa996d.zip | |
Use new style instance logging in compute api.
Change-Id: I4e5682e902faf0fbcea5c85900d8e3da89482cc8
| -rw-r--r-- | nova/compute/api.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/nova/compute/api.py b/nova/compute/api.py index 78655bed4..bf03cb10b 100644 --- a/nova/compute/api.py +++ b/nova/compute/api.py @@ -828,8 +828,8 @@ class API(base.Base): vm_states.ERROR]) def soft_delete(self, context, instance): """Terminate an instance.""" - instance_uuid = instance["uuid"] - LOG.debug(_("Going to try to soft delete %s"), instance_uuid) + LOG.debug(_('Going to try to soft delete instance'), + instance=instance) if instance['disable_terminate']: return @@ -848,8 +848,8 @@ class API(base.Base): self._cast_compute_message('power_off_instance', context, instance) else: - LOG.warning(_("No host for instance %s, deleting immediately"), - instance["uuid"]) + LOG.warning(_('No host for instance, deleting immediately'), + instance=instance) try: self.db.instance_destroy(context, instance['id']) except exception.InstanceNotFound: @@ -882,7 +882,7 @@ class API(base.Base): vm_states.SHUTOFF, vm_states.STOPPED]) def delete(self, context, instance): """Terminate an instance.""" - LOG.debug(_("Going to try to terminate %s"), instance["uuid"]) + LOG.debug(_("Going to try to terminate instance"), instance=instance) if instance['disable_terminate']: return @@ -920,7 +920,7 @@ class API(base.Base): def stop(self, context, instance, do_cast=True): """Stop an instance.""" instance_uuid = instance["uuid"] - LOG.debug(_("Going to try to stop %s"), instance_uuid) + LOG.debug(_("Going to try to stop instance"), instance=instance) self.update(context, instance, @@ -939,7 +939,7 @@ class API(base.Base): """Start an instance.""" vm_state = instance["vm_state"] instance_uuid = instance["uuid"] - LOG.debug(_("Going to try to start %s"), instance_uuid) + LOG.debug(_("Going to try to start instance"), instance=instance) if vm_state == vm_states.SHUTOFF: if instance['shutdown_terminate']: |
