Search in sources :

Example 1 with ExecutionStateRestRep

use of com.emc.vipr.model.catalog.ExecutionStateRestRep in project coprhd-controller by CoprHD.

the class OrdersApi method orderExecution.

public static void orderExecution(String orderId) {
    ViPRCatalogClient2 catalog = getCatalogClient();
    ExecutionStateRestRep executionState = catalog.orders().getExecutionState(uri(orderId));
    List<OrderLogRestRep> logs = catalog.orders().getLogs(uri(orderId));
    List<ExecutionLogRestRep> taskLogs = catalog.orders().getExecutionLogs(uri(orderId));
    renderApi(newExecutionInfo(executionState, logs, taskLogs));
}
Also used : ExecutionStateRestRep(com.emc.vipr.model.catalog.ExecutionStateRestRep) OrderLogRestRep(com.emc.vipr.model.catalog.OrderLogRestRep) ViPRCatalogClient2(com.emc.vipr.client.ViPRCatalogClient2) ExecutionLogRestRep(com.emc.vipr.model.catalog.ExecutionLogRestRep)

Example 2 with ExecutionStateRestRep

use of com.emc.vipr.model.catalog.ExecutionStateRestRep in project coprhd-controller by CoprHD.

the class OrderTextCreator method map.

public static ExecutionStateRestRep map(ExecutionState from) {
    if (from == null) {
        return null;
    }
    ExecutionStateRestRep to = new ExecutionStateRestRep();
    to.setAffectedResources(Lists.newArrayList(from.getAffectedResources()));
    to.setCurrentTask(from.getCurrentTask());
    to.setEndDate(from.getEndDate());
    to.setExecutionStatus(from.getExecutionStatus());
    to.setStartDate(from.getStartDate());
    to.setLastUpdated(from.getLastUpdated());
    return to;
}
Also used : ExecutionStateRestRep(com.emc.vipr.model.catalog.ExecutionStateRestRep)

Aggregations

ExecutionStateRestRep (com.emc.vipr.model.catalog.ExecutionStateRestRep)2 ViPRCatalogClient2 (com.emc.vipr.client.ViPRCatalogClient2)1 ExecutionLogRestRep (com.emc.vipr.model.catalog.ExecutionLogRestRep)1 OrderLogRestRep (com.emc.vipr.model.catalog.OrderLogRestRep)1