Liron Ar has posted comments on this change. Change subject: core: Add snapshot to the OVF generation ......................................................................
Patch Set 1: (1 comment) http://gerrit.ovirt.org/#/c/25947/1/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/OvfDataUpdater.java File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/OvfDataUpdater.java: Line 370: List<VM> vms = getVmDao().getVmsByIds(idsToProcess); Line 371: for (VM vm : vms) { Line 372: if (VMStatus.ImageLocked != vm.getStatus()) { Line 373: updateVmDisksFromDb(vm); Line 374: vm.setSnapshots(getSnapshotDao().getAllWithConfiguration(vm.getId())); 1. There's no need to load the snapshots if the disks checks hasn't passed succesfully, same way that we don't load the disks if the vm is locked. 2. you should load the images for each of the disks IIRC, take a look on what's being done on ExportVmCommand and handle synchronization with other flows like preview/restore/stateless run. Line 375: if (verifyDisksNotLocked(vm.getDiskList()) && verifySnapshotsNotLocked(vm.getSnapshots())) { Line 376: loadVmData(vm); Line 377: Long currentDbGeneration = getVmStaticDao().getDbGeneration(vm.getId()); Line 378: // currentDbGeneration can be null in case that the vm was deleted during the run of OvfDataUpdater. -- To view, visit http://gerrit.ovirt.org/25947 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I8ba05c2e362fb9b22d6b4fb5a14698ad99d7bd1e Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Maor Lipchuk <[email protected]> Gerrit-Reviewer: Allon Mureinik <[email protected]> Gerrit-Reviewer: Liron Ar <[email protected]> Gerrit-Reviewer: [email protected] Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
