Search in sources :

Example 1 with DeleteVolumePoolCmdResponse

use of com.cloud.server.api.response.netapp.DeleteVolumePoolCmdResponse in project cloudstack by apache.

the class DeleteVolumePoolCmd method execute.

@Override
public void execute() throws ResourceUnavailableException, InsufficientCapacityException, ServerApiException, ConcurrentOperationException, ResourceAllocationException {
    try {
        netappMgr.deletePool(poolName);
        DeleteVolumePoolCmdResponse response = new DeleteVolumePoolCmdResponse();
        response.setResponseName(getCommandName());
        this.setResponseObject(response);
    } catch (InvalidParameterValueException e) {
        throw new ServerApiException(ApiErrorCode.PARAM_ERROR, e.toString());
    } catch (ResourceInUseException e) {
        throw new ServerApiException(ApiErrorCode.RESOURCE_IN_USE_ERROR, e.toString());
    }
}
Also used : ServerApiException(org.apache.cloudstack.api.ServerApiException) InvalidParameterValueException(com.cloud.exception.InvalidParameterValueException) ResourceInUseException(com.cloud.exception.ResourceInUseException) DeleteVolumePoolCmdResponse(com.cloud.server.api.response.netapp.DeleteVolumePoolCmdResponse)

Aggregations

InvalidParameterValueException (com.cloud.exception.InvalidParameterValueException)1 ResourceInUseException (com.cloud.exception.ResourceInUseException)1 DeleteVolumePoolCmdResponse (com.cloud.server.api.response.netapp.DeleteVolumePoolCmdResponse)1 ServerApiException (org.apache.cloudstack.api.ServerApiException)1