Yevgeny Zaspitsky has posted comments on this change.

Change subject: core: Added DAO for HostNetworkQos entities
......................................................................


Patch Set 1:

(1 comment)

http://gerrit.ovirt.org/#/c/34121/1/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/QosQueryBase.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/QosQueryBase.java:

Line 17:         QosType qosType = getParameters().getQosType();
Line 18:         if (qosType == null) {
Line 19:             return getDbFacade().getQosBaseDao();
Line 20:         }
Line 21:         switch (qosType) {
> this switch should be encapsulated in separate method.
I'd create QosDaoRegistrar class so every Dao would register itself with the 
QosType it treats. The class would keep all daos in a Map with QosType as the 
key then this method implementation will reside there and this class will 
become redundant.

Again, this is not your code, but we should strive to the best we can.
Line 22:         case STORAGE:
Line 23:             qosDao = getDbFacade().getStorageQosDao();
Line 24:             break;
Line 25:         case CPU:


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I90535167d324c80aa9de7a735a010818ab45e428
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Lior Vernia <[email protected]>
Gerrit-Reviewer: Alona Kaplan <[email protected]>
Gerrit-Reviewer: Lior Vernia <[email protected]>
Gerrit-Reviewer: Martin Mucha <[email protected]>
Gerrit-Reviewer: Moti Asayag <[email protected]>
Gerrit-Reviewer: Yevgeny Zaspitsky <[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

Reply via email to