Package org.apache.airavata.registry.api.workflow

Examples of org.apache.airavata.registry.api.workflow.WorkflowInstanceNode


  }

  @Override
  public String getWorkflowInstanceNodeInput(String experimentId, String workflowInstanceId, String nodeId)
      throws AiravataAPIInvocationException {
    return getWorkflowInstanceNodeInput(new WorkflowInstanceNode(new WorkflowInstance(experimentId, workflowInstanceId), nodeId));
  }
View Full Code Here


  }

  private Map<WorkflowInstanceNode, String> groupNodePortData(List<WorkflowNodeIOData> list) {
    Map<WorkflowInstanceNode,String> portData=new HashMap<WorkflowInstanceNode, String>();
    for (WorkflowNodeIOData data : list) {
      portData.put(new WorkflowInstanceNode(new WorkflowInstance(data.getExperimentId(), data.getWorkflowInstanceId()), data.getNodeId()), data.getValue());
    }
    return portData;
  }
View Full Code Here

  }

  @Override
  public String getWorkflowInstanceNodeOutput(String experimentId, String workflowInstanceId, String nodeId)
      throws AiravataAPIInvocationException {
    return getWorkflowInstanceNodeOutput(new WorkflowInstanceNode(new WorkflowInstance(experimentId, workflowInstanceId), nodeId));

  }
View Full Code Here

  @Override
  public WorkflowInstanceNodeStatus getWorkflowInstanceNodeStatus(
      String experimentId, String workflowInstaceId, String nodeId)
      throws AiravataAPIInvocationException {
    return getWorkflowInstanceNodeStatus(new WorkflowInstanceNode(new WorkflowInstance(experimentId,workflowInstaceId),nodeId));
  }
View Full Code Here


  @Override
  public void updateWorkflowNodeStatus(String workflowInstanceId,
      String nodeId, ExecutionStatus status) throws RegistryException {
    updateWorkflowNodeStatus(new WorkflowInstanceNode(new WorkflowInstance(workflowInstanceId, workflowInstanceId), nodeId), status);
  }
View Full Code Here

    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());
  }
View Full Code Here

      String workflowInstanceId, String nodeId) throws RegistryException {
    if (!isWorkflowInstanceNodePresent(workflowInstanceId,nodeId)){
      throw new WorkflowInstanceNodeDoesNotExistsException(workflowInstanceId,nodeId);
    }
    NodeDataResource nodeData = jpa.getWorker().getWorkflowInstance(workflowInstanceId).getNodeData(nodeId);
    WorkflowInstanceNodeData data = new WorkflowInstanceNodeData(new WorkflowInstanceNode(new WorkflowInstance(nodeData.getWorkflowDataResource().getExperimentID(),nodeData.getWorkflowDataResource().getWorkflowInstanceID()),nodeData.getNodeID()));
    data.setInput(nodeData.getInputs());
    data.setOutput(nodeData.getOutputs());
    //TODO setup status
    return data;
  }
View Full Code Here

        keywords[i] = ((InputNode) node).getName();
        values[i] = ((InputNode) node).getDefaultValue();
                //Saving workflow input Node data before running the workflow
                WorkflowNodeType workflowNodeType = new WorkflowNodeType();
                workflowNodeType.setNodeType(WorkflowNodeType.WorkflowNode.INPUTNODE);
                WorkflowInstanceNode workflowInstanceNode = new WorkflowInstanceNode(new WorkflowExecution(getConfig().getTopic(),
                        getConfig().getTopic()), node.getID());
                this.getConfig().getConfiguration().getAiravataAPI().getProvenanceManager().setWorkflowInstanceNodeInput(workflowInstanceNode, keywords[i] + "=" + (String) values[i]);
                this.getConfig().getConfiguration().getAiravataAPI().getProvenanceManager().setWorkflowNodeType(workflowInstanceNode, workflowNodeType);
      }
      this.config.getNotifier().workflowStarted(values, keywords);
View Full Code Here

            ((OutputNode) node).setDescription(val.toString());
          }
                    // Saving output Node data in to database
                    WorkflowNodeType workflowNodeType = new WorkflowNodeType();
                    workflowNodeType.setNodeType(WorkflowNodeType.WorkflowNode.OUTPUTNODE);
                    WorkflowInstanceNode workflowInstanceNode = new WorkflowInstanceNode(new WorkflowExecution(config.getTopic(), config.getTopic()), node.getID());
                    String portname = node.getName();
                    String portValue = ((OutputNode) node).getDescription();
                    this.getConfig().getConfiguration().getAiravataAPI().getProvenanceManager().setWorkflowInstanceNodeOutput(workflowInstanceNode, portname + "=" + portValue);
                    this.getConfig().getConfiguration().getAiravataAPI().getProvenanceManager().setWorkflowNodeType(workflowInstanceNode, workflowNodeType);
View Full Code Here

  public void updateWorkflowNodeStatus(String workflowInstanceId,
      String nodeId, State status) throws RegistryException {
        if (provenanceRegistry != null){
            provenanceRegistry.updateWorkflowNodeStatus(workflowInstanceId, nodeId, status);
        }else {
            updateWorkflowNodeStatus(new WorkflowInstanceNode(new WorkflowExecution(workflowInstanceId, workflowInstanceId), nodeId), status);
        }

  }
View Full Code Here

TOP

Related Classes of org.apache.airavata.registry.api.workflow.WorkflowInstanceNode

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.