Yair Zaslavsky has posted comments on this change. Change subject: engine:BLL Command to Start Remove Gluster volume brick ......................................................................
Patch Set 8: (2 comments) .................................................... File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/gluster/StartRemoveGlusterVolumeBricksCommand.java Line 50: return false; Line 51: } Line 52: Line 53: if (getParameters().getBricks().isEmpty()) { Line 54: return failCanDoAction(VdcBllMessages.ACTION_TYPE_FAILED_BRICKS_REQUIRED); But these checks can be in the validator as wel... like a validation method if we can remove the brick. Line 55: } Line 56: if (getGlusterVolume().getBricks().size() == 1 || Line 57: getGlusterVolume().getBricks().size() <= getParameters().getBricks().size()) { Line 58: return failCanDoAction(VdcBllMessages.ACTION_TYPE_FAILED_CAN_NOT_REMOVE_ALL_BRICKS_FROM_VOLUME); .................................................... File backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/gluster/GlusterBrickDaoDbFacadeImpl.java Line 60: } Line 61: Line 62: @Override Line 63: public void updateBrickStatuses(List<GlusterBrickEntity> bricks) { Line 64: for (GlusterBrickEntity brick : bricks) { Use the spring-jdbc batch infra here. this DAO should be mass operations DAO for that. Line 65: updateBrickStatus(brick.getId(), brick.getStatus()); Line 66: } Line 67: } Line 68: -- To view, visit http://gerrit.ovirt.org/18923 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ie3ee4620b75b4b714087dbf1dec3720661a5ce6b Gerrit-PatchSet: 8 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Ramesh N <rnach...@redhat.com> Gerrit-Reviewer: Kanagaraj M <kmayi...@redhat.com> Gerrit-Reviewer: Ramesh N <rnach...@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