Omer Frenkel has posted comments on this change.

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


Patch Set 4: (2 inline comments)

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/GetGlusterVolumeAdvancedDetailsQuery.java
Line 38:     @Override
Line 39:     protected void executeQueryCommand() {
Line 40:         clusterId = getParameters().getClusterId();
Line 41:         detailRequired = getParameters().isDetailRequired();
Line 42:         volumeId = getParameters().getVolumeId();
i think initialization code should be in constructor but its only my opinion, 
not mandatory
Line 43:         if (volumeId != null) {
Line 44:             brick = getBrick(getParameters().getBrickId());
Line 45:             
getQueryReturnValue().setReturnValue(fetchAdvancedDetails(getGlusterVolumeDao().getById(volumeId).getName()));
Line 46:         } else {


Line 41:         detailRequired = getParameters().isDetailRequired();
Line 42:         volumeId = getParameters().getVolumeId();
Line 43:         if (volumeId != null) {
Line 44:             brick = getBrick(getParameters().getBrickId());
Line 45:             
getQueryReturnValue().setReturnValue(fetchAdvancedDetails(getGlusterVolumeDao().getById(volumeId).getName()));
i think this is a potential NPE, using rest user might supply bad volume id..
Line 46:         } else {
Line 47:             getQueryReturnValue().setReturnValue(getServiceInfo());
Line 48:         }
Line 49:     }


--
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: 4
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Shireesh Anjal <san...@redhat.com>
Gerrit-Reviewer: Gilad Chaplik <gchap...@redhat.com>
Gerrit-Reviewer: Kanagaraj M <kmayi...@redhat.com>
Gerrit-Reviewer: Michael Pasternak <mpast...@redhat.com>
Gerrit-Reviewer: Omer Frenkel <ofren...@redhat.com>
Gerrit-Reviewer: Sahina Bose <sab...@redhat.com>
Gerrit-Reviewer: Shireesh Anjal <san...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to