Omer Frenkel has posted comments on this change.

Change subject: core: handling memory snapshots on export/import vm
......................................................................


Patch Set 17: (4 inline comments)

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ExportVmCommand.java
Line 358:         params.setSourceDomainId(storageDomainId);
Line 359:         params.setEntityInfo(getParameters().getEntityInfo());
Line 360:         params.setParentParameters(getParameters());
Line 361: 
Line 362:         if (getStoragePool().getStorageType().isBlockDomain()) {
please add a short comment about this logic
Line 363:             params.setUseCopyCollapse(true);
Line 364:             params.setVolumeType(VolumeType.Sparse);
Line 365:             params.setVolumeFormat(VolumeFormat.RAW);
Line 366:         }


....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ImportVmCommand.java
Line 451:                 storageDomain.getId().toString(), 
storagePoolId.toString(),
Line 452:                 guids.get(2), guids.get(3), guids.get(4), 
guids.get(5));
Line 453:     }
Line 454: 
Line 455:     private VM getVmFromSnapshot(Snapshot snapshot) {
you can reuse this code
Line 456:         String vmConfiguration = snapshot.getVmConfiguration();
Line 457:         // active snapshot
Line 458:         if (vmConfiguration == null) {
Line 459:             return getVm();


....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/memory/MemoryImageRemover.java
Line 54:                 
getDbFacade().getSnapshotDao().getNumOfSnapshotsByMemory(memoryVolume) == 1;
Line 55:     }
Line 56: 
Line 57:     protected boolean removeMemoryVolumes(String memVols, boolean 
startPollingTasks) {
Line 58:         // this is temp code until it will be implemented in SPM
remove this comment or explain it
Line 59:         List<Guid> guids = GuidUtils.getGuidListFromString(memVols);
Line 60: 
Line 61:         if (guids.size() == 6) {
Line 62:             // get all vm disks in order to check post zero - if one 
of the


....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmHandler.java
Line 513:         }
Line 514:         return null;
Line 515:     }
Line 516: 
Line 517:     public static StorageDomain findStorageDomainForMemory(Guid 
storagePoolId, long sizeRequested,
looks like the method above..
Line 518:             Map<StorageDomain, Integer> domain2reservedSpaceInDomain) 
{
Line 519:         List<StorageDomain> domainsInPool = 
DbFacade.getInstance().getStorageDomainDao().getAllForStoragePool(storagePoolId);
Line 520:         for (StorageDomain currDomain : domainsInPool) {
Line 521:             long reservedSizeForDisks = 
domain2reservedSpaceInDomain.containsKey(currDomain) ?


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

Gerrit-MessageType: comment
Gerrit-Change-Id: Ifae3d5dd6bdeca04d5b5c9eee2dbe93e3eb03cea
Gerrit-PatchSet: 17
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Arik Hadas <aha...@redhat.com>
Gerrit-Reviewer: Allon Mureinik <amure...@redhat.com>
Gerrit-Reviewer: Arik Hadas <aha...@redhat.com>
Gerrit-Reviewer: Michal Skrivanek <michal.skriva...@redhat.com>
Gerrit-Reviewer: Omer Frenkel <ofren...@redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to