public WorkflowInstanceNodeStatus getWorkflowNodeStatus(
WorkflowInstanceNode workflowNode) throws RegistryException {
String id = workflowNode.getWorkflowInstance().getWorkflowInstanceId();
String nodeId = workflowNode.getNodeId();
if (!isWorkflowInstanceNodePresent(id, nodeId)){
throw new WorkflowInstanceNodeDoesNotExistsException(id, nodeId);
}
WorkflowDataResource workflowInstance = jpa.getWorker().getWorkflowInstance(id);
NodeDataResource nodeData = workflowInstance.getNodeData(nodeId);
return new WorkflowInstanceNodeStatus(new WorkflowInstanceNode(new WorkflowInstance(workflowInstance.getExperimentID(), workflowInstance.getWorkflowInstanceID()), nodeData.getNodeID()), nodeData.getStatus()==null?null:ExecutionStatus.valueOf(nodeData.getStatus()),nodeData.getLastUpdateTime());
}