Gilad Chaplik has posted comments on this change.

Change subject: db: Numa support database implementation
......................................................................


Patch Set 21:

(4 comments)

http://gerrit.ovirt.org/#/c/26996/21/backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VdsCpuStatisticsDAO.java
File 
backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VdsCpuStatisticsDAO.java:

Line 47:      *
Line 48:      * @param vdsId
Line 49:      *            the vds id
Line 50:      */
Line 51:     void removeAllCpuStatisticsByVdsId(Guid vdsId);
> If host is removed, then cpu statistics will be deleted cascade.
Done
Line 52: 


http://gerrit.ovirt.org/#/c/26996/21/backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VmStaticDAODbFacadeImpl.java
File 
backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/VmStaticDAODbFacadeImpl.java:

Line 103:                 .addValue("serial_number_policy", 
vm.getSerialNumberPolicy() == null ? null : 
vm.getSerialNumberPolicy().getValue())
Line 104:                 .addValue("custom_serial_number", 
vm.getCustomSerialNumber())
Line 105:                 .addValue("is_boot_menu_enabled", 
vm.isBootMenuEnabled())
Line 106:                 .addValue("numatune_mode", 
vm.getNumaTuneMode().getValue())
Line 107:                 .addValue("vm_numa_node_count", vm.getvNumaNodeList() 
== null ? 0 : vm.getvNumaNodeList().size());
> ok. I will update this count in our dao when save or delete vNumaNode. Is t
I don't like data duplication. the count is in the vnode list.
we can consider removing it, I don't see the benefit.
Line 108:     }
Line 109: 
Line 110:     @Override
Line 111:     public void remove(Guid id) {


http://gerrit.ovirt.org/#/c/26996/21/packaging/dbscripts/numa_sp.sql
File packaging/dbscripts/numa_sp.sql:

Line 4: -- [numa_node] Table
Line 5: --
Line 6: 
Line 7: 
Line 8: Create or replace FUNCTION InsertNumaNode(v_numa_node_id UUID,
> It affects two tables, that will be done in dao with transaction.
Done
Line 9:  v_vds_id UUID,
Line 10:  v_vm_id UUID,
Line 11:  v_numa_node_index SMALLINT,
Line 12:  v_mem_total BIGINT,


http://gerrit.ovirt.org/#/c/26996/21/packaging/dbscripts/upgrade/03_05_0330_add_numa_tables_and_columns.sql
File packaging/dbscripts/upgrade/03_05_0330_add_numa_tables_and_columns.sql:

Line 90:     PERFORM fn_db_add_column('vm_static', 'vm_numa_node_count', 
'smallint');
Line 91: 
Line 92:     -- Add columns in table vds_dynamic
Line 93:     PERFORM fn_db_add_column('vds_dynamic', 'auto_numa_balancing', 
'smallint');
Line 94:     PERFORM fn_db_add_column('vds_dynamic', 'vds_numa_node_count', 
'smallint');
> Need this field to do the query in future. We will provide the query that f
[***] no, triggers are db oriented, we also support DBs that don't support 
triggers.

I still don't understand why we need this field (we'll deal with the future in 
the future).
Line 95:     PERFORM fn_db_add_column('vds_dynamic', 'is_numa_supported', 
'boolean');
Line 96: 
Line 97: END; $procedure$
Line 98: LANGUAGE plpgsql;


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I2507c084aa214bcfb65e860b11ed7dcf02af50cc
Gerrit-PatchSet: 21
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Xiaolei Shi <xiao-lei....@hp.com>
Gerrit-Reviewer: Doron Fediuck <dfedi...@redhat.com>
Gerrit-Reviewer: Eli Mesika <emes...@redhat.com>
Gerrit-Reviewer: Gilad Chaplik <gchap...@redhat.com>
Gerrit-Reviewer: Jason Liao <chuan.l...@hp.com>
Gerrit-Reviewer: Martin Sivák <msi...@redhat.com>
Gerrit-Reviewer: Xiaolei Shi <xiao-lei....@hp.com>
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to