Maor Lipchuk has posted comments on this change.
Change subject: core: Support undoing diskless previews (#848298)
......................................................................
Patch Set 10: (2 inline comments)
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RestoreAllSnapshotsCommand.java
Line 83:
Line 84: restoreSnapshotAndRemoveObsoleteSnapshots();
Line 85:
Line 86: boolean succeeded = true;
Line 87: if (!getImagesList().isEmpty()) {
No need to use this if, the for loop will not be accessed.
Line 88: for (DiskImage image : getImagesList()) {
Line 89: if (image.getimageStatus() != ImageStatus.ILLEGAL) {
Line 90: ImagesContainterParametersBase params = new
RestoreFromSnapshotParameters(image.getImageId(),
Line 91: getVmId(), targetSnapshot,
removedSnapshotId);
Line 103:
Line 104: if (!getTaskIdList().isEmpty()) {
Line 105: deleteOrphanedImages();
Line 106: } else {
Line 107: endActionOnVmConfiguration();
Why calling to the method instead simply call:
UpdateVmInSpm(getVm().getstorage_pool_id(), Arrays.asList(getVm()));
The VM is not locked and we also know that it is not null
Line 108: }
Line 109:
Line 110: setSucceeded(succeeded);
Line 111: }
--
To view, visit http://gerrit.ovirt.org/6676
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic62eee3cfb03abd21905ad6aa132c8cc10dbfb70
Gerrit-PatchSet: 10
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Ayal Baron <[email protected]>
Gerrit-Reviewer: Daniel Erez <[email protected]>
Gerrit-Reviewer: Liron Aravot <[email protected]>
Gerrit-Reviewer: Maor Lipchuk <[email protected]>
Gerrit-Reviewer: Omer Frenkel <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches