Shireesh Anjal has posted comments on this change.

Change subject: gluster: Use brick server for advanced details
......................................................................


Patch Set 1: (3 inline comments)

Thanks Sahina, new patch-set to follow.

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/GetGlusterVolumeAdvancedDetailsQuery.java
Line 35:         super(params);
Line 36:     }
Line 37: 
Line 38:     @Override
Line 39:     protected void executeQueryCommand() {
Done
Line 40:         clusterId = getParameters().getClusterId();
Line 41:         detailRequired = getParameters().isDetailRequired();
Line 42:         volumeId = getParameters().getVolumeId();
Line 43:         if (volumeId != null) {


Line 121: 
Line 122:         // brick server is down
Line 123:         return super.getUpServerId(clusterId);
Line 124:     }
Line 125: 
This method is being called twice. In one place, we're fetching the volume 
based on volume id passed as parameter, whereas in the other, we're fetching an 
appropriate type of volume from db, and then sending it's name as argument. So 
accepting volumeId here is not a good idea as it might result in the db query 
being fired twice in the second case.
Line 126:     private GlusterVolumeAdvancedDetails fetchAdvancedDetails(String 
volumeName) {
Line 127:         VDSReturnValue returnValue =
Line 128:                 
runVdsCommand(VDSCommandType.GetGlusterVolumeAdvancedDetails,
Line 129:                         new 
GlusterVolumeAdvancedDetailsVDSParameters(getUpServerId(),


Line 127:         VDSReturnValue returnValue =
Line 128:                 
runVdsCommand(VDSCommandType.GetGlusterVolumeAdvancedDetails,
Line 129:                         new 
GlusterVolumeAdvancedDetailsVDSParameters(getUpServerId(),
Line 130:                                 clusterId,
Line 131:                                 volumeName,
Done
Line 132:                                 brick.getQualifiedName(),
Line 133:                                 detailRequired));
Line 134:         return (GlusterVolumeAdvancedDetails) 
returnValue.getReturnValue();
Line 135:     }


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

Gerrit-MessageType: comment
Gerrit-Change-Id: Id4acb0bbe84bacab714926d69b639bbda970df9a
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Shireesh Anjal <[email protected]>
Gerrit-Reviewer: Gilad Chaplik <[email protected]>
Gerrit-Reviewer: Kanagaraj M <[email protected]>
Gerrit-Reviewer: Omer Frenkel <[email protected]>
Gerrit-Reviewer: Sahina Bose <[email protected]>
Gerrit-Reviewer: Shireesh Anjal <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to