use of com.emc.storageos.cinder.model.QosAssociationsRestResp in project coprhd-controller by CoprHD.
the class QosService method getQosAssociations.
/**
* Get the detailed list of all associations for a given qos
*
* @prereq none
*
* @param openstackTenantId the URN of the tenant
*
* @brief List volumes in detail
* @return Volume detailed list
*/
@GET
@Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
@Path("/{qos_id}/associations")
@CheckPermission(roles = { Role.SYSTEM_MONITOR, Role.TENANT_ADMIN }, acls = { ACL.ANY })
public QosAssociationsRestResp getQosAssociations(@PathParam("tenant_id") String openstackTenantId, @PathParam("qos_id") String qosId) {
_log.debug("START get qos associations");
QosAssociationsRestResp objQosRestResp = new QosAssociationsRestResp();
URI qosURI = URIUtil.createId(QosSpecification.class, qosId);
QosSpecification qosSpecification = _dbClient.queryObject(QosSpecification.class, qosURI);
if (qosSpecification != null && hasTenantUsageAclOnQos(qosSpecification)) {
objQosRestResp.getAssociation().add(getQosAssociation(qosSpecification));
}
_log.debug("END get qos association");
return objQosRestResp;
}
Aggregations