git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/Common/workspace-task-executor-library@167369 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
394c34cd7b
commit
3d34c1931e
|
@ -47,7 +47,7 @@ public class DataMinerAccessPoint {
|
|||
|
||||
/** The map call back. */
|
||||
// Fully synchronized HashMap
|
||||
private Map<String, TaskExecutionStatus> mapExecutionTask = Collections.synchronizedMap(new HashMap<>());
|
||||
private Map<String, TaskExecutionStatus> mapExecutionTask = Collections.synchronizedMap(new HashMap<String, TaskExecutionStatus>());
|
||||
|
||||
|
||||
/**
|
||||
|
@ -263,83 +263,6 @@ public class DataMinerAccessPoint {
|
|||
}
|
||||
|
||||
|
||||
// /**
|
||||
// * Start computation on data miner.
|
||||
// *
|
||||
// * @param algConfiguration the alg configuration
|
||||
// * @param computationId the computation id
|
||||
// * @param sClient the s client
|
||||
// * @return the task execution status
|
||||
// */
|
||||
// private TaskExecutionStatus startComputationOnDataMiner(BaseTaskConfiguration algConfiguration, final ComputationId computationId, final SClient sClient){
|
||||
//
|
||||
// TaskExecutionStatus taskExecutiontatus = new TaskExecutionStatus(algConfiguration, computationId);
|
||||
//
|
||||
// logger.debug("Requesting operation progress");
|
||||
// ComputationStatus computationStatus = null;
|
||||
// try {
|
||||
// computationStatus = sClient.getComputationStatus(computationId);
|
||||
// } catch (Exception e) {
|
||||
// logger.error(e.getLocalizedMessage());
|
||||
// e.printStackTrace();
|
||||
//
|
||||
// }
|
||||
// logger.debug("ComputationStatus: " + computationStatus);
|
||||
// if (computationStatus == null) {
|
||||
// logger.error("ComputationStatus is null");
|
||||
// return taskExecutiontatus;
|
||||
// }
|
||||
//
|
||||
// Status status = computationStatus.getStatus();
|
||||
// if (status == null) {
|
||||
// logger.error("Status is null");
|
||||
// return taskExecutiontatus;
|
||||
// }
|
||||
//
|
||||
// taskExecutiontatus.setCurrentMessage(computationStatus.getMessage());
|
||||
//
|
||||
// switch (status) {
|
||||
// case ACCEPTED:
|
||||
// logger.debug("Operation "+TaskStatus.ACCEPTED);
|
||||
// taskExecutiontatus.setStatus(TaskStatus.ACCEPTED);
|
||||
// taskExecutiontatus.addLog("Status "+TaskStatus.ACCEPTED+": "+computationStatus.getMessage());
|
||||
// saveTask(algConfiguration, taskExecutiontatus);
|
||||
// break;
|
||||
// case CANCELLED:
|
||||
// logger.debug("Operation "+TaskStatus.CANCELLED);
|
||||
// taskExecutiontatus.setStatus(TaskStatus.CANCELLED);
|
||||
// taskExecutiontatus.addLog("Status "+TaskStatus.CANCELLED+": "+computationStatus.getMessage());
|
||||
// saveTask(algConfiguration, taskExecutiontatus);
|
||||
// break;
|
||||
// case COMPLETE:
|
||||
// logger.debug("Operation "+TaskStatus.COMPLETED);
|
||||
// taskExecutiontatus.setStatus(TaskStatus.COMPLETED);
|
||||
// taskExecutiontatus.addLog("Status "+TaskStatus.COMPLETED+": "+computationStatus.getMessage());
|
||||
// saveTask(algConfiguration, taskExecutiontatus);
|
||||
// break;
|
||||
// case FAILED:
|
||||
// logger.debug("Operation "+TaskStatus.FAILED);
|
||||
// taskExecutiontatus.setStatus(TaskStatus.FAILED);
|
||||
// taskExecutiontatus.setCurrentMessage(computationStatus.getError().getMessage());
|
||||
// taskExecutiontatus.addLog("Status "+TaskStatus.FAILED+": "+computationStatus.getMessage());
|
||||
// saveTask(algConfiguration, taskExecutiontatus);
|
||||
// break;
|
||||
// case RUNNING:
|
||||
// logger.debug("Operation "+TaskStatus.ONGOING);
|
||||
// taskExecutiontatus.setStatus(TaskStatus.ONGOING);
|
||||
// taskExecutiontatus.addLog("Status "+TaskStatus.ONGOING+": "+computationStatus.getMessage());
|
||||
// taskExecutiontatus.setPercentCompleted((float) computationStatus.getPercentage());
|
||||
// saveTask(algConfiguration, taskExecutiontatus);
|
||||
// break;
|
||||
// default:
|
||||
// break;
|
||||
//
|
||||
// }
|
||||
//
|
||||
// return taskExecutiontatus;
|
||||
// }
|
||||
|
||||
|
||||
/**
|
||||
* Retrieve output.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue