Oved Ourfali has posted comments on this change.

Change subject: core: Fix skip fencing if host connected to storage
......................................................................


Patch Set 2:

(3 comments)

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

Line 137:         if (wasSkippedDueToPolicy(result)) {
Line 138:             // when fencing is skipped due to policy we want to 
suppress command result logging, because
Line 139:             // we fire an alert in VdsNotRespondingTreatment
Line 140:             setCommandShouldBeLogged(false);
Line 141:             setSucceeded(false);
so skip fencing == failure?
this code is confusing, so I guess you're right here, but just making sure.
Line 142:         } else {
Line 143:             setSucceeded(result.getSucceeded());
Line 144:         }
Line 145:         setActionReturnValue(result);


Line 428: 
Line 429:     /**
Line 430:      * Returns numbers of agents for which fencing operation was 
skipped
Line 431:      */
Line 432:     protected int countSkippedOperations(List<VDSFenceReturnValue> 
results) {
If we know the policy, and we checked it, why do we need this logic?
Line 433:         int numOfSkipped = 0;
Line 434:         for (VDSFenceReturnValue result : results) {
Line 435:             if (wasSkippedDueToPolicy(result)) {
Line 436:                 numOfSkipped++;


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

Line 160:             VDSFenceReturnValue result = 
getMostRelevantResult(results);
Line 161: 
Line 162:             if (result != null) {
Line 163:                 if (result.getSucceeded()) {
Line 164:                     int numOfSkipped = 
countSkippedOperations(results);
why would one agent skip, and not the other?
the policy should be "above" the agent.
Line 165:                     if (numOfSkipped == 0) {
Line 166:                         // no agent reported that stop operation was 
skipped, continue with stop operation
Line 167:                         handleSpecificCommandActions();
Line 168:                     } else {


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I84fa56e75adf988ce36b1154269dab8974cf05bf
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Martin Peřina <mper...@redhat.com>
Gerrit-Reviewer: Eli Mesika <emes...@redhat.com>
Gerrit-Reviewer: Martin Peřina <mper...@redhat.com>
Gerrit-Reviewer: Ori Liel <ol...@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