Alona Kaplan has posted comments on this change. Change subject: engine: read 'interface' property on from HostDevListByCaps result ......................................................................
Patch Set 2: (6 comments) https://gerrit.ovirt.org/#/c/37385/2//COMMIT_MSG Commit Message: Line 3: AuthorDate: 2015-02-03 14:09:20 +0200 Line 4: Commit: Alona Kaplan <[email protected]> Line 5: CommitDate: 2015-02-03 14:09:20 +0200 Line 6: Line 7: engine: read 'interface' property on from HostDevListByCaps result > please delete the "on" Done Line 8: Line 9: Change-Id: Id4deae6a655fa1db96411a99a9189f975e3667dd https://gerrit.ovirt.org/#/c/37385/2/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/HostDevice.java File backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/HostDevice.java: Line 14: private String productId; Line 15: private String vendorName; Line 16: private String vendorId; Line 17: private String parentPhysicalFunction; Line 18: private Integer totalVirtualFunctions; > wouldn't it be better to have NetworkHostDevice which extends this entity w HostNicVfsConfigHelper contains the business logic for analyzing the network host devices (there is more than one type, not all of them has networkInterfaceName), I don't think it is better to move this logic to HostDeviceDaoDbFacadeImpl and then using instanceof to identify the type of the device. Line 19: private String networkInterfaceName; Line 20: private Guid vmId; Line 21: Line 22: public Guid getHostId() { Line 178: Line 179: @Override Line 180: public String toString() { Line 181: return String.format("HostDevice{hostId=%s, deviceName='%s', parentDeviceName='%s', capability='%s', iommuGroup=%d, " + Line 182: "productName='%s', productId='%s', vendorName='%s', vendorId='%s', parentPhysicalFunction='%s', totalVirtualFunctions=%s, networkInterfaceName='%s', vmId=%s}", > the lines are two big. please reformat / split to additional line. Done Line 183: hostId, deviceName, parentDeviceName, capability, iommuGroup, productName, productId, vendorName, vendorId, parentPhysicalFunction, totalVirtualFunctions, networkInterfaceName, vmId); Line 184: } https://gerrit.ovirt.org/#/c/37385/2/backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/FixturesTool.java File backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/FixturesTool.java: Line 720: public static final Guid CPU_PROFILE_1 = new Guid("fd81f1e1-785b-4579-ab75-1419ebb87052"); Line 721: public static final Guid CPU_PROFILE_2 = new Guid("fd81f1e1-785b-4579-ab75-1419ebb87053"); Line 722: Line 723: public static final Guid NETWORK_HOST_DEVICE_HOST_ID = new Guid("afce7a39-8e8c-4819-ba9c-796d316592e6"); Line 724: public static final String NETWORK_HOST_DEVICE_DEVICE_NAME = "net_enp5s16f4_3e_fa_b0_f6_48_a3"; > s/NETWORK_HOST_DEVICE_DEVICE_NAME/NETWORK_HOST_DEVICE_NAME Done https://gerrit.ovirt.org/#/c/37385/2/backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/HostDeviceDaoTest.java File backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/HostDeviceDaoTest.java: Line 50: } Line 51: Line 52: @Test Line 53: public void saveNetworkDevice() { Line 54: > please delete the first empty line Done Line 55: HostDevice netDevice = generateNewEntity(); Line 56: Line 57: netDevice.setCapability("net"); Line 58: netDevice.setNetworkInterfaceName("eth1"); https://gerrit.ovirt.org/#/c/37385/2/packaging/dbscripts/upgrade/03_06_0870_add_iface_column_to_host_device_table.sql File packaging/dbscripts/upgrade/03_06_0870_add_iface_column_to_host_device_table.sql: Line 1: select fn_db_add_column('host_device', 'net_iface_name', 'VARCHAR(255)'); > isn't 255 too long ? done- changed to varying(50), same as name column in vds_interface. -- To view, visit https://gerrit.ovirt.org/37385 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Id4deae6a655fa1db96411a99a9189f975e3667dd Gerrit-PatchSet: 2 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Alona Kaplan <[email protected]> Gerrit-Reviewer: Alona Kaplan <[email protected]> Gerrit-Reviewer: Eli Mesika <[email protected]> Gerrit-Reviewer: Martin Betak <[email protected]> Gerrit-Reviewer: Moti Asayag <[email protected]> Gerrit-Reviewer: [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
