Eli Mesika has uploaded a new change for review. Change subject: core: Host can not be restarted by ...(#852464) ......................................................................
core: Host can not be restarted by ...(#852464) Host can not be restarted by Power Management if not in maintenance status https://bugzilla.redhat.com/show_bug.cgi?id=852464 Adding a condition to StopVdsCommand canDoAction to perform the Host status check only if Stop was activated as a single command and not as part of the Restart implementation which is Stop->Wait for Status to be off->Start->Wait for Status to be on Change-Id: I19a0bf8ace353047274290f309fd0468d6e9c8b7 Signed-off-by: Eli Mesika <[email protected]> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/StopVdsCommand.java 1 file changed, 5 insertions(+), 3 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/59/7559/1 diff --git a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/StopVdsCommand.java b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/StopVdsCommand.java index e3fdacb..b1fd8b7 100644 --- a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/StopVdsCommand.java +++ b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/StopVdsCommand.java @@ -21,9 +21,11 @@ @Override protected boolean canDoAction() { boolean retValue = super.canDoAction(); - if (getVds() != null && getVds().getstatus() != VDSStatus.Maintenance) { - addCanDoActionMessage(VdcBllMessages.VDS_STATUS_NOT_VALID_FOR_STOP); - retValue = false; + if (getParameters().getParentCommand() == VdcActionType.Unknown) { + if (getVds() != null && getVds().getstatus() != VDSStatus.Maintenance) { + addCanDoActionMessage(VdcBllMessages.VDS_STATUS_NOT_VALID_FOR_STOP); + retValue = false; + } } return retValue; } -- To view, visit http://gerrit.ovirt.org/7559 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I19a0bf8ace353047274290f309fd0468d6e9c8b7 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Eli Mesika <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
