Search in sources :

Example 31 with ViPRCatalogClient2

use of com.emc.vipr.client.ViPRCatalogClient2 in project coprhd-controller by CoprHD.

the class AssetOptionUtils method getAssetOptions.

public static List<AssetOption> getAssetOptions(String assetType, Map<String, String> assetParameters) {
    ViPRCatalogClient2 catalog = getCatalogClient();
    AssetOptionsRequest request = new AssetOptionsRequest();
    request.setTenantId(uri(Models.currentAdminTenant()));
    request.setAvailableAssets(assetParameters);
    return catalog.assetOptions().getAssetOptions(assetType, request);
}
Also used : AssetOptionsRequest(com.emc.vipr.model.catalog.AssetOptionsRequest) ViPRCatalogClient2(com.emc.vipr.client.ViPRCatalogClient2)

Example 32 with ViPRCatalogClient2

use of com.emc.vipr.client.ViPRCatalogClient2 in project coprhd-controller by CoprHD.

the class SupportPackageCreator method getOrderTextCreator.

private OrderTextCreator getOrderTextCreator(OrderRestRep order) {
    ViPRCatalogClient2 client = catalogApi();
    OrderTextCreator creator = new OrderTextCreator();
    creator.setOrder(order);
    creator.setService(client.services().get(order.getCatalogService()));
    creator.setState(client.orders().getExecutionState(order.getId()));
    creator.setLogs(client.orders().getLogs(order.getId()));
    creator.setExeLogs(client.orders().getExecutionLogs(order.getId()));
    return creator;
}
Also used : OrderTextCreator(com.emc.storageos.db.client.util.OrderTextCreator) ViPRCatalogClient2(com.emc.vipr.client.ViPRCatalogClient2)

Aggregations

ViPRCatalogClient2 (com.emc.vipr.client.ViPRCatalogClient2)32 OrderRestRep (com.emc.vipr.model.catalog.OrderRestRep)7 ApprovalRestRep (com.emc.vipr.model.catalog.ApprovalRestRep)4 CatalogServiceRestRep (com.emc.vipr.model.catalog.CatalogServiceRestRep)4 NamedRelatedResourceRep (com.emc.storageos.model.NamedRelatedResourceRep)2 ViPRHttpException (com.emc.vipr.client.exceptions.ViPRHttpException)2 URI (java.net.URI)2 Date (java.util.Date)2 OrderTextCreator (com.emc.storageos.db.client.util.OrderTextCreator)1 AssetDependencyRequest (com.emc.vipr.model.catalog.AssetDependencyRequest)1 AssetOptionsRequest (com.emc.vipr.model.catalog.AssetOptionsRequest)1 ExecutionLogRestRep (com.emc.vipr.model.catalog.ExecutionLogRestRep)1 ExecutionStateRestRep (com.emc.vipr.model.catalog.ExecutionStateRestRep)1 ExecutionWindowRestRep (com.emc.vipr.model.catalog.ExecutionWindowRestRep)1 OrderLogRestRep (com.emc.vipr.model.catalog.OrderLogRestRep)1 Reference (com.emc.vipr.model.catalog.Reference)1 ScheduledEventRestRep (com.emc.vipr.model.catalog.ScheduledEventRestRep)1 ApprovalRequestInfo (models.datatable.ApprovalsDataTable.ApprovalRequestInfo)1 DateTime (org.joda.time.DateTime)1 Util (play.mvc.Util)1