Michael Pasternak has posted comments on this change. Change subject: restapi: Throw exception if setting lower VM pool size ......................................................................
Patch Set 2: I would prefer that you didn't submit this (1 inline comment) .................................................... File backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendVmPoolResource.java Line 103: final int currentVmCount = current.getAssignedVmsCount(); Line 104: Line 105: int size = 0; Line 106: if (incoming.isSetSize()) { Line 107: // in case the value is negative, the backend command will fail on canDoAction indeed, but can-do-action is VM_POOL_CANNOT_CREATE_WITH_NO_VMS, what is a bit misleading, you should add new one detecting that new-size < current-size and provide error accordingly Line 108: size = incoming.getSize() - currentVmCount; Line 109: } Line 110: Line 111: final org.ovirt.engine.core.common.businessentities.VmPool entity = map(incoming, current); -- To view, visit http://gerrit.ovirt.org/13978 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ibe4ad50e6962159df5891be4653bc05eb3dfd237 Gerrit-PatchSet: 2 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Libor Spevak <lspe...@redhat.com> Gerrit-Reviewer: Libor Spevak <lspe...@redhat.com> Gerrit-Reviewer: Michael Pasternak <mpast...@redhat.com> Gerrit-Reviewer: Omer Frenkel <ofren...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches