Shahar Havivi has posted comments on this change. Change subject: engine: cannot set payload and cloud-init on same devices. ......................................................................
Patch Set 1: (4 comments) http://gerrit.ovirt.org/#/c/33318/1/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java: Line 678: getVm().setInitializationType(InitializationType.CloudInit); Line 679: } Line 680: } Line 681: } Line 682: } else { > what about this case? if user selected sysprep/cloud init in run once (then right, Need to consider the option that the user will pass payload and sysprep/cloud-init (currently via REST) - in this case we need to fail with canDoAction Line 683: getVm().setInitializationType(getParameters().getInitializationType()); Line 684: } Line 685: Line 686: // get what cpu flags should be passed to vdsm according to cluster Line 698: } Line 699: } Line 700: Line 701: // Device name CDROM/Floppy Line 702: protected boolean isPaloadExists(String deviceName) { > Paload->Payload Done Line 703: if (getVm().getVmPayload() != null) { Line 704: return true; Line 705: } Line 706: List<VmDevice> vmDevices = Line 699: } Line 700: Line 701: // Device name CDROM/Floppy Line 702: protected boolean isPaloadExists(String deviceName) { Line 703: if (getVm().getVmPayload() != null) { > need to check sent payload is of the same device (floppy/cd) as deviceName, Done Line 704: return true; Line 705: } Line 706: List<VmDevice> vmDevices = Line 707: DbFacade.getInstance() Line 704: return true; Line 705: } Line 706: List<VmDevice> vmDevices = Line 707: DbFacade.getInstance() Line 708: .getVmDeviceDao() > you can use the existing getVmDeviceDao() method Done Line 709: .getVmDeviceByVmIdTypeAndDevice(getVm().getId(), Line 710: VmDeviceGeneralType.DISK, Line 711: deviceName); Line 712: for (VmDevice vmDevice : vmDevices) { -- To view, visit http://gerrit.ovirt.org/33318 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ic5b701f058a2d87b2836d337f822d2f012d10bbe Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Shahar Havivi <shav...@redhat.com> Gerrit-Reviewer: Michal Skrivanek <michal.skriva...@redhat.com> Gerrit-Reviewer: Omer Frenkel <ofren...@redhat.com> Gerrit-Reviewer: Shahar Havivi <shav...@redhat.com> Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches