Skip to content

Commit 6987f23

Browse files
committed
Pragrammatically Answer HA question posted in vCenter since it will block CloudStack from continuously operating on the VM
1 parent fa7d9ad commit 6987f23

1 file changed

Lines changed: 6 additions & 11 deletions

File tree

vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualMachineMO.java

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -248,17 +248,12 @@ public void run() {
248248
}
249249
});
250250

251-
try {
252-
boolean result = _context.getVimClient().waitForTask(morTask);
253-
if (result) {
254-
_context.waitForTaskProgressDone(morTask);
255-
return true;
256-
} else {
257-
s_logger.error("VMware powerOnVM_Task failed due to " + TaskMO.getTaskFailureInfo(_context, morTask));
258-
}
259-
} finally {
260-
// make sure to let VM question monitor exit
261-
flags[0] = true;
251+
boolean result = _context.getVimClient().waitForTask(morTask);
252+
if (result) {
253+
_context.waitForTaskProgressDone(morTask);
254+
return true;
255+
} else {
256+
s_logger.error("VMware powerOnVM_Task failed due to " + TaskMO.getTaskFailureInfo(_context, morTask));
262257
}
263258

264259
return false;

0 commit comments

Comments
 (0)