Package org.apache.oodt.cas.workflow.system

Examples of org.apache.oodt.cas.workflow.system.XmlRpcWorkflowManagerClient


        return true;
    }

    private void updateStatus(String status, Metadata met) {
        String workflowInstId = met.getMetadata(WORKFLOW_INST_ID);
        XmlRpcWorkflowManagerClient wClient = getWmClientFromMetadata(met);

        try {
            if (!wClient.updateWorkflowInstanceStatus(workflowInstId, status)) {
                LOG.log(Level.WARNING,
                        "Unable to update status for workflow instance: ["
                                + workflowInstId + "] to : [" + status + "]");
            }
        } catch (Exception ignore) {
View Full Code Here


        }
    }

    private void updateMetadata(Metadata met) {
        String workflowInstId = met.getMetadata(WORKFLOW_INST_ID);
        XmlRpcWorkflowManagerClient wClient = getWmClientFromMetadata(met);

        try {
            if (!wClient.updateMetadataForWorkflow(workflowInstId, met)) {
                LOG.log(Level.WARNING,
                        "Unable to update Metadata for workflow instance: ["
                                + workflowInstId + "]");
            }
        } catch (Exception ignore) {
View Full Code Here

    }

    private void setWorkflowInstanceCurrentTaskStartDateTime(
            String startDateTime, Metadata met) {
        String workflowInstId = met.getMetadata(WORKFLOW_INST_ID);
        XmlRpcWorkflowManagerClient wClient = getWmClientFromMetadata(met);

        try {
            if (!wClient.setWorkflowInstanceCurrentTaskStartDateTime(
                    workflowInstId, startDateTime)) {
                LOG.log(Level.WARNING,
                        "Unable to update start date time for workflow instance: ["
                                + workflowInstId + "]");
            }
View Full Code Here

    }

    private void setWorkflowInstanceCurrentTaskEndDateTime(String endDateTime,
            Metadata met) {
        String workflowInstId = met.getMetadata(WORKFLOW_INST_ID);
        XmlRpcWorkflowManagerClient wClient = getWmClientFromMetadata(met);

        try {
            if (!wClient.setWorkflowInstanceCurrentTaskEndDateTime(
                    workflowInstId, endDateTime)) {
                LOG.log(Level.WARNING,
                        "Unable to update end date time for workflow instance: ["
                                + workflowInstId + "]");
            }
View Full Code Here

            // try to default to a workflow mgr on localhost
            // most likely won't work, but worth trying
            workflowMgrUrlStr = "http://localhost:9001";
        }

        return new XmlRpcWorkflowManagerClient(
                safeGetUrlFromString(workflowMgrUrlStr));
    }
View Full Code Here

    }

    private void setWorkflowMgrUrl(String wmUrlStr) {
        System.out.println("Connecting to workflow mgr: ["+wmUrlStr+"]");
        this.client = new XmlRpcWorkflowManagerClient(safeGetUrl(wmUrlStr));
    }
View Full Code Here

   * org.apache.oodt.cas.workflow.structs.WorkflowTaskConfiguration)
   */
  @Override
  public void run(Metadata metadata, WorkflowTaskConfiguration config)
      throws WorkflowTaskInstanceException {
    XmlRpcWorkflowManagerClient wm = null;

    try {
      wm = new XmlRpcWorkflowManagerClient(new URL(
          metadata.getMetadata(CoreMetKeys.WORKFLOW_MANAGER_URL)));
      wm.sendEvent(config.getProperty("eventName"), metadata);
    } catch (Exception e) {
      throw new WorkflowTaskInstanceException(e.getMessage());
    }
  }
View Full Code Here

  public InstanceRepoCleaner() {
  }

  public InstanceRepoCleaner(String wmUrlStr) throws Exception {
    this.wm = new XmlRpcWorkflowManagerClient(new URL(wmUrlStr));
  }
View Full Code Here

   protected XmlRpcWorkflowManagerClient createWorkflowManagerClient()
         throws Exception {
      String url = pgeMetadata.getMetadata(WORKFLOW_MANAGER_URL);
      logger.info("Creating WorkflowManager client for url [" + url + "]");
      Validate.notNull(url, "Must specify " + WORKFLOW_MANAGER_URL);
      return new XmlRpcWorkflowManagerClient(new URL(url));
   }
View Full Code Here

  private XmlRpcWorkflowManagerClient wm;

  public WorkflowMgrConn(String wmUrlStr) {
    try {
      this.wm = new XmlRpcWorkflowManagerClient(new URL(wmUrlStr));
    } catch (MalformedURLException e) {
      LOG.log(Level.SEVERE, "Unable to contact Workflow Manager at URL: ["
          + wmUrlStr + "]: Message: " + e.getMessage());
      this.wm = null;
    }
View Full Code Here

TOP

Related Classes of org.apache.oodt.cas.workflow.system.XmlRpcWorkflowManagerClient

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.