Allon Mureinik has posted comments on this change.

Change subject: core: add locks to VmTemplate commands (#761515)
......................................................................


Patch Set 6: (1 inline comment)

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmTemplateHandler.java
Line 58:      *
Line 59:      * @return True if template is at valid state, false otherwise.
Line 60:      */
Line 61:     public static boolean isTemplateStatusIsNotLocked(Guid id) {
Line 62:         boolean toReturn = 
VmTemplateHandler.BlankVmTemplateId.equals(id);
Just do an early return here.
Line 63:         if (!toReturn) {
Line 64:             VmTemplate template = 
DbFacade.getInstance().getVmTemplateDAO().get(id);
Line 65:             if (!((template != null) && (template.getstatus() != 
VmTemplateStatus.Locked))) {
Line 66:                 toReturn = true;


--
To view, visit http://gerrit.ovirt.org/8013
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I2d5b6518bbf19077ae5822b9359a6147c87d0f46
Gerrit-PatchSet: 6
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Liron Aravot <lara...@redhat.com>
Gerrit-Reviewer: Allon Mureinik <amure...@redhat.com>
Gerrit-Reviewer: Ayal Baron <aba...@redhat.com>
Gerrit-Reviewer: Daniel Erez <de...@redhat.com>
Gerrit-Reviewer: Liron Aravot <lara...@redhat.com>
Gerrit-Reviewer: Michael Kublin <mkub...@redhat.com>
Gerrit-Reviewer: Tal Nisan <tni...@redhat.com>
Gerrit-Reviewer: Vered Volansky <vvola...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to