yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #27140
[Bug 1325905] Re: Cleaning on failed spawn in Ironic driver may override original exception
The latest code on Master is already using save_and_reraise_exception.
https://github.com/openstack/nova/blob/master/nova/virt/ironic/driver.py#L641-L656
Marking this bug an Invalid
** Changed in: nova
Status: Confirmed => Invalid
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1325905
Title:
Cleaning on failed spawn in Ironic driver may override original
exception
Status in OpenStack Bare Metal Provisioning Service (Ironic):
Invalid
Status in OpenStack Compute (Nova):
Invalid
Bug description:
In Nova driver we have the following code:
# trigger the node deploy
try:
icli.call("node.set_provision_state", node_uuid,
ironic_states.ACTIVE)
except (exception.NovaException, # Retry failed
ironic_exception.InternalServerError, # Validations
ironic_exception.BadRequest) as e: # Maintenance
msg = (_("Failed to request Ironic to provision instance "
"%(inst)s: %(reason)s") % {'inst': instance['uuid'],
'reason': str(e)})
LOG.error(msg)
self._cleanup_deploy(node, instance, network_info)
raise exception.InstanceDeployFailure(msg)
If exception happens inside _cleanup_deploy, it will hide the original
one. excutils.save_and_reraise_exception() should be used here.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ironic/+bug/1325905/+subscriptions