CS-13376: Vm is stuck in Stopping state when MS is rebooted after the stop command was issued, but answer wasn't recieved from the backend yet..removing trailing whitespaces in the code

This commit is contained in:
Pranav Saxena 2012-07-04 22:04:20 +05:30
parent df67c4986e
commit a4740b314f
1 changed files with 1 additions and 4 deletions

View File

@ -1818,16 +1818,13 @@ public class VirtualMachineManagerImpl implements VirtualMachineManager, Listene
else if(info == null && vm.getState() == State.Stopping) { //Handling CS-13376
Host host = _hostDao.findByGuid(info.getHosUuid());
if(host != null ){
s_logger.warn("Marking the VM as Stopped as it was still stopping on the CS" +info.name);
vm.setState(State.Stopped); // Setting the VM as stopped on the DB and clearing it from the host
vm.setHostId(null);
vm.setLastHostId(host.getId());
_vmDao.persist(vm);
_vmDao.persist(vm);
}
}
}
for (final AgentVmInfo left : infos.values()) {