You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2020/08/26 06:57:00 UTC

[GitHub] [cloudstack] Spaceman1984 commented on a change in pull request #4284: Fixed delayed power state update after vm shutdown

Spaceman1984 commented on a change in pull request #4284:
URL: https://github.com/apache/cloudstack/pull/4284#discussion_r477075338



##########
File path: engine/orchestration/src/main/java/com/cloud/vm/VirtualMachineManagerImpl.java
##########
@@ -1657,6 +1657,10 @@ protected boolean sendStop(final VirtualMachineGuru guru, final VirtualMachinePr
                     return false;
                 }
 
+                final UserVmVO userVm = _userVmDao.findById(vm.getId());
+                userVm.setPowerState(PowerState.PowerOff);
+                _userVmDao.update(userVm.getId(), userVm);
+
                 guru.finalizeStop(profile, answer);

Review comment:
       np @rhtyd, I'll move it down.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org