Sharad Mishra has posted comments on this change.
Change subject: core: cleanup Vm
......................................................................
Patch Set 1: (3 inline comments)
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ClearNonResponsiveVdsVmsCommand.java
Line 47: Collections.sort(vms, Collections.reverseOrder(new
VmsComparer()));
Line 48: java.util.ArrayList<VdcActionParametersBase> runVmParamsList =
Line 49: new java.util.ArrayList<VdcActionParametersBase>();
Line 50: for (VM vm : vms) {
Line 51: if (vm.isAutoStartup()) {
I would rather call it 'isAutoStart()' but can live with 'isAutoStartup()'.
Line 52: runVmParamsList.add(new RunVmParams(vm.getId()));
Line 53: }
Line 54: VDSReturnValue returnValue = Backend
Line 55: .getInstance()
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/FenceVdsBaseCommand.java
Line 203: VDSCommandType.DestroyVm,
Line 204: new
DestroyVmVDSCommandParameters(new Guid(vm.getmigrating_to_vds().toString()), vm
Line 205: .getId(), true, false,
0));
Line 206: log.infoFormat("Stopped migrating vm: {0} on vds:
{1}", vm.getVmName(), vm.getmigrating_to_vds());
Line 207: }
why not refactor getmigrating_to_vds?
On second thought, lets leave it for another patch, this one is already too big
without it :-)
Line 208: } catch (RuntimeException ex) {
Line 209: log.infoFormat("Could not stop migrating vm: {0} on
vds: {1}, Error: {2}", vm.getVmName(),
Line 210: vm.getmigrating_to_vds(), ex.getMessage());
Line 211: // intentionally ingnored
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/utils/VmDeviceUtils.java
Line 91: * @param newVmBase
Line 92: */
Line 93: private static void updateAudioDevice(VM oldVm, VmBase newVmBase) {
Line 94: // for desktop, if the os type has changed, recreate Audio
devices
Line 95: if (newVmBase.getvm_type() == VmType.Desktop && oldVm.getOs()
!= newVmBase.getos()) {
not changing the VmBase getos() ?
Line 96: Guid vmId = oldVm.getId();
Line 97: // remove any old sound device
Line 98: List<VmDevice> list =
Line 99: DbFacade.getInstance()
--
To view, visit http://gerrit.ovirt.org/9394
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ia02ddd858626553eca5de2310e8921cfac71957c
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Laszlo Hornyak <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Sharad Mishra <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches