Gilad Chaplik has uploaded a new change for review. Change subject: core: checking quota even if can-do fails (#846777) ......................................................................
core: checking quota even if can-do fails (#846777) https://bugzilla.redhat.com/846777 there is a problem in quota flow, that I validate and set (set is the wrong part here) quota even if the command fails. that causes a lot of problems when the command fails and the quota get validated, and the use of that command is getting cached... therefore, the validate & set quota will be invoked iff all the command will go on to the execute part. Change-Id: I0f4dd77582985f521ef0009b421cbd0e83466b57 Signed-off-by: Gilad Chaplik <gchap...@redhat.com> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/85/7585/1 diff --git a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java index 91b866d..6422e86 100644 --- a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java +++ b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java @@ -496,7 +496,7 @@ returnValue = IsUserAutorizedToRunAction() && IsBackwardsCompatible() && validateInputs() && acquireLock() && canDoAction(); - if (this instanceof Quotable) { + if (returnValue && this instanceof Quotable) { returnValue &= ((Quotable) this).validateAndSetQuota(); } if (!returnValue && getReturnValue().getCanDoActionMessages().size() > 0) { -- To view, visit http://gerrit.ovirt.org/7585 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I0f4dd77582985f521ef0009b421cbd0e83466b57 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Gilad Chaplik <gchap...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches