Moti Asayag has posted comments on this change.

Change subject: db: aggregate qos and storage qos impl
......................................................................


Patch Set 6:

(1 comment)

http://gerrit.ovirt.org/#/c/27094/6/packaging/dbscripts/upgrade/03_05_0330_qos_and_storage_impl.sql
File packaging/dbscripts/upgrade/03_05_0330_qos_and_storage_impl.sql:

Line 27: -- add index on storage_pool_id
Line 28: CREATE INDEX IDX_qos_storage_pool_id ON qos (storage_pool_id);
Line 29: 
Line 30: -- add index on qos_type
Line 31: CREATE INDEX IDX_qos_type ON qos (qos_type);
> > you're introducing a wrong db design
Adding an index on a column which isn't being searched is not the right thing 
to do, no matter how db optimizer tries to compensate such design.

If you had a query as mentioned in my previous comment, than you could claim 
that both indexes are deserved and we could argue what is the correct approach 
for that.

Since this isn't the case, and any access to that table is being performed by 
data-center-id first, it is useless to introduce any other indices, which no 
query was introduced for.


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I1a9af59277b5055453159f002f19046c0051d63b
Gerrit-PatchSet: 6
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Gilad Chaplik <gchap...@redhat.com>
Gerrit-Reviewer: Allon Mureinik <amure...@redhat.com>
Gerrit-Reviewer: Doron Fediuck <dfedi...@redhat.com>
Gerrit-Reviewer: Eli Mesika <emes...@redhat.com>
Gerrit-Reviewer: Gilad Chaplik <gchap...@redhat.com>
Gerrit-Reviewer: Kobi Ianko <k...@redhat.com>
Gerrit-Reviewer: Lior Vernia <lver...@redhat.com>
Gerrit-Reviewer: Liron Ar <lara...@redhat.com>
Gerrit-Reviewer: Moti Asayag <masa...@redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzasl...@redhat.com>
Gerrit-Reviewer: Yevgeny Zaspitsky <yzasp...@redhat.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