Allon Mureinik has posted comments on this change.

Change subject: core: Update managed device map when importing a cloned VM.
......................................................................


Patch Set 6:

(3 comments)

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ImportVmCommand.java
Line 832:         }
Line 833:     }
Line 834: 
Line 835:     /**
Line 836:      * Generates a new <code>GUID</code> for disk and its volumes and 
updates all the related attributes.
I'd use {@link Guid} instead of <code>GUID</code>
Line 837:      *
Line 838:      * @param diskList
Line 839:      *            - All the disk's volumes
Line 840:      * @param disk


....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/MoveOrCopyTemplateCommand.java
Line 371:         return true;
Line 372:     }
Line 373: 
Line 374:     /**
Line 375:      * Cloning a new disk and all its volumes with a new generated 
id. <BR/> The disk will have the same parameters as <code>disk</code>.<BR/> Also
s/<BR/>/<br/>
Also, start the next sentance on a new line.
Line 376:      * adding the disk to <code>newDiskGuidForDisk</code> map, so we 
will be able to link between the new cloned disk
Line 377:      * and the old disk id.
Line 378:      *
Line 379:      * @param diskImagesList


Line 413:     protected Guid generateNewDiskId(DiskImage disk) {
Line 414:         Guid newGuidForDisk = Guid.newGuid();
Line 415: 
Line 416:         // Copy the disk so it will preserve the old disk id and 
image id.
Line 417:         newDiskIdForDisk.put(newGuidForDisk, DiskImage.copyOf(disk));
Note that DiskImage.copyOf changes the status of the disk - is this intentional 
here? (is it even an issue?)
Line 418:         disk.setId(newGuidForDisk);
Line 419:         disk.setImageId(Guid.newGuid());
Line 420:         return newGuidForDisk;
Line 421:     }


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I65a99cc0783f670b9288cc9a066cda4d253492a6
Gerrit-PatchSet: 6
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Maor Lipchuk <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Maor Lipchuk <[email protected]>
Gerrit-Reviewer: Sergey Gotliv <[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

Reply via email to