commit 63381a15ac3c2e36f5521f8a77108664f89bfab5
Author: Phil Day <email address hidden>
Date: Wed Nov 27 17:31:23 2013 +0000
Failure during termination should always leave state as Error(Deleting)
Delete is a non-reversible operation for the user, and once the
user has indicated that they want to delete the instance from that
point on is the system's problem to complete the delete as soon as
possible.
If anything fails during the delete that the system cannot recover
from then the instance should be left in an Error(Deleting) state.
Anything else, in particular reverting to an Active(None) state, makes
it look like the system has ignored the request.
Currently InstanceTerminationFailure is explicitly caught, but the
exception does not propagate so the instance_fault wrapper does not
get a chance to log the failure. Also terminate_instance is wrapped
by reverts_task_state which resets the state to Active(None)
This change removes the revert_task_state wrapper and catches all
exceptions so that unhandled exceptions always leave the instance
in Error(Deleting)
Reviewed: https:/ /review. openstack. org/58829 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=63381a15ac3 c2e36f5521f8a77 108664f89bfab5
Committed: https:/
Submitter: Jenkins
Branch: master
commit 63381a15ac3c2e3 6f5521f8a771086 64f89bfab5
Author: Phil Day <email address hidden>
Date: Wed Nov 27 17:31:23 2013 +0000
Failure during termination should always leave state as Error(Deleting)
Delete is a non-reversible operation for the user, and once the
user has indicated that they want to delete the instance from that
point on is the system's problem to complete the delete as soon as
possible.
If anything fails during the delete that the system cannot recover
from then the instance should be left in an Error(Deleting) state.
Anything else, in particular reverting to an Active(None) state, makes
it look like the system has ignored the request.
Currently InstanceTermina tionFailure is explicitly caught, but the
exception does not propagate so the instance_fault wrapper does not
get a chance to log the failure. Also terminate_instance is wrapped
by reverts_task_state which resets the state to Active(None)
This change removes the revert_task_state wrapper and catches all
exceptions so that unhandled exceptions always leave the instance
in Error(Deleting)
Change-Id: I5fb1bbd5603579 2f566a6e076edfe 7a69df006ef
Closes-Bug: 1254122