Oved Ourfali has posted comments on this change.

Change subject: core: Skip hard fencing if network unstable...
......................................................................


Patch Set 2: Code-Review+1

(1 comment)

http://gerrit.ovirt.org/#/c/31304/2/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VdsEventListener.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VdsEventListener.java:

Line 268:     private boolean isBelowNetworkUnstableThreshold(VDS vds) {
Line 269:         VDSGroup cluster = 
DbFacade.getInstance().getVdsGroupDao().get(vds.getVdsGroupId());
Line 270:         boolean result = true;
Line 271:         if 
(cluster.getFencingPolicy().isSkipFencingIfNetworkUnstable()) {
Line 272:             List<VDS> hosts = 
DbFacade.getInstance().getVdsDao().getAllForVdsGroup(cluster.getId());
consider an alternative ti query for ones with status using 
getAllForVdsGroupWithStatus, doing two queries here, one for each status.
Seems like it would be more efficient for larger number of hosts.
Not critical, though.
Line 273:             double hostsNumber = hosts.size();
Line 274:             List<VDS> hostsWithUnstableNetwork = 
LinqUtils.filter(hosts,
Line 275:                     new Predicate<VDS>() {
Line 276:                         @Override


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

Gerrit-MessageType: comment
Gerrit-Change-Id: Iff1b4108da76286907773575c101c73aaacbca41
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Eli Mesika <emes...@redhat.com>
Gerrit-Reviewer: Oved Ourfali <oourf...@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