Shubhendu Tripathi has posted comments on this change.

Change subject: gluster: Added additional can do action check
......................................................................


Patch Set 5:

(2 comments)

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/gluster/GlusterBrickValidator.java
Line 125:         for (GlusterBrickEntity paramBrick : bricks) {
Line 126:             for (GlusterBrickEntity brick : searchBricks) {
Line 127:                 // If parameter brick directory matches with any 
brick no need to continue further to check
Line 128:                 if 
(paramBrick.getBrickDirectory().equals(brick.getBrickDirectory())
Line 129:                         && paramBrick.getServerId() == 
brick.getServerId()) {
added check for brickId as well
Line 130:                     found = true;
Line 131:                     break;
Line 132:                 }
Line 133:                 // early return


Line 127:                 // If parameter brick directory matches with any 
brick no need to continue further to check
Line 128:                 if 
(paramBrick.getBrickDirectory().equals(brick.getBrickDirectory())
Line 129:                         && paramBrick.getServerId() == 
brick.getServerId()) {
Line 130:                     found = true;
Line 131:                     break;
Below if found is false we return from the method so we are not continuing with 
further checks. So the moment we dont find one brick in the list we fail. There 
is no need for reseting the flag.
Line 132:                 }
Line 133:                 // early return
Line 134:                 // if one of the brick not found return then and there
Line 135:                 if (!found) {


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

Gerrit-MessageType: comment
Gerrit-Change-Id: Id7f5d3b48985552aa5f74178008beb39ee7a06f9
Gerrit-PatchSet: 5
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Shubhendu Tripathi <shtri...@redhat.com>
Gerrit-Reviewer: Kanagaraj M <kmayi...@redhat.com>
Gerrit-Reviewer: Omer Frenkel <ofren...@redhat.com>
Gerrit-Reviewer: Sahina Bose <sab...@redhat.com>
Gerrit-Reviewer: Shubhendu Tripathi <shtri...@redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzasl...@redhat.com>
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