Omer Frenkel has posted comments on this change.
Change subject: engine : Hotplug - a new command added, main logic
......................................................................
Patch Set 5: (3 inline comments)
i also added a comment in patchset 2
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/HotPlugDiskToVmCommand.java
Line 40:
getVds().getvds_group_compatibility_version().getValue())) {
if vm is null, then getVds() will be null, and its NPE, the getVm() != null
comes only later...
any way we have a different mechanism to block new commands by version in the
infrastructure, you can add an entry to action_version_map, and it should be
blocked without explicit check. (need to verify it though)
Line 72: } else if (VdcActionType.HotPlugDiskToVm ==
getActionType() && diskImage.getPlugged()) {
you could use inheritance here, instead of being aware to the action type,
write a method that check what is relevant to this action, and override it in
the other action.. i think its nicer but my opinion only.
....................................................
File
backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/vdsbroker/HotPlugDiskVDSCommand.java
Line 39: private Map<String, String> initDriveData() {
isnt this logic shared from createVdsCommand? if so, maybe we can reuse it, if
not, forget it
--
To view, visit http://gerrit.ovirt.org/1019
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: If3190a8f82c7abee7af2ab470b37a2cdc36009d9
Gerrit-PatchSet: 5
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Michael Kublin <[email protected]>
Gerrit-Reviewer: Jonathan Choate <[email protected]>
Gerrit-Reviewer: Michael Kublin <[email protected]>
Gerrit-Reviewer: Omer Frenkel <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches