Yair Zaslavsky has posted comments on this change. Change subject: core: adding engine Maintenance and Prepare mode.(#868639) ......................................................................
Patch Set 8: (3 inline comments) Some comments. In addition - what about adding this to engine-config? How are we going to modify this value at vdc_options? .................................................... File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/Backend.java Line 293: public VdcReturnValueBase RunAction(VdcActionType actionType, VdcActionParametersBase parameters) { Line 294: VdcReturnValueBase returnValue = isModeAllowToRunAction(actionType); Line 295: if (returnValue != null) { Line 296: return returnValue; Line 297: } I think the name of isModeAllowToRunAction is a bit misleading. Maybe should be "getRunActionBlockingReturnValue" , in a sense that if "null" is returned, this means that the action is not blocked from execution? Line 298: return runActionImpl(actionType, parameters, false, null); Line 299: } Line 300: Line 301: private VdcReturnValueBase isModeAllowToRunAction(VdcActionType actionType) { Line 299: } Line 300: Line 301: private VdcReturnValueBase isModeAllowToRunAction(VdcActionType actionType) { Line 302: EngineWorkingMode mode = Line 303: EngineWorkingMode.valueOf(Config.<String> GetValue(ConfigValues.EngineMode).toUpperCase()); Itamar - yes, we should. Line 304: switch (mode) { Line 305: case MAINTENANCEMODE: Line 306: return getErrorCommandReturnValue(VdcBllMessages.ENGINE_IS_RUNNING_IN_MAINTENANCE_MODE); Line 307: case PREPAREMODE: .................................................... File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/EngineWorkingMode.java Line 1: package org.ovirt.engine.core.bll; Line 2: Line 3: public enum EngineWorkingMode { Line 4: REGULAR, Itamar - are yo suggesting s/REGULAR/ACTIVE or adding another enum literal? If you're suggesting adding another enum literal, what is the difference between ACTIVE and REGULAR? Line 5: MAINTENANCEMODE, Line 6: PREPAREMODE; -- To view, visit http://gerrit.ovirt.org/8669 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Idd86f9f9008a447e160edc913ee8a6cd70912dcb Gerrit-PatchSet: 8 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Eli Mesika <emes...@redhat.com> Gerrit-Reviewer: Barak Azulay <bazu...@redhat.com> Gerrit-Reviewer: Eli Mesika <emes...@redhat.com> Gerrit-Reviewer: Itamar Heim <ih...@redhat.com> Gerrit-Reviewer: Michael Kublin <mkub...@redhat.com> Gerrit-Reviewer: Yair Zaslavsky <yzasl...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches