Michael Kublin has posted comments on this change. Change subject: core: Prestarted Vm (2) ......................................................................
Patch Set 9: (4 inline comments) you remove a query at Dao, please also remove appropriate queries at .sql files .................................................... File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AttachUserToVmFromPoolAndRunCommand.java Line 109: boolean isPrestartedVm = false; Please make a query outside a lock section or at least most of them Line 111: List<vm_pool_map> vmPoolMaps = getListOfVmsInPool(getParameters().getVmPoolId()); The following query will run twice VmDynamic vmDynamic = DbFacade.getInstance().getVmDynamicDAO().get(vm_guid); for every vm at worse case. There acn be better solution Line 112: setVmId(getPrestartedVmToAttach(vmPoolMaps)); why not use a variable and after that setVmId() - code is clear Line 117: } change order, Const.equals() -- To view, visit http://gerrit.ovirt.org/1798 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ie3c0b0d69c0da82d3ba2dcbcf045cd92a6db7bef Gerrit-PatchSet: 9 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Muli Salem <msa...@redhat.com> Gerrit-Reviewer: Michael Kublin <mkub...@redhat.com> Gerrit-Reviewer: Muli Salem <msa...@redhat.com> Gerrit-Reviewer: Omer Frenkel <ofren...@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