Package xsul.lead

Examples of xsul.lead.LeadContextHeader


     * Constructs a LeadContextHeaderHelper.
     *
     */
    public LeadContextHeaderHelper() {
        // The default experiment and user will be will be overwritten.
        this.leadContextHeader = new LeadContextHeader(DEFAULT_EXPERIMENT,
                DEFAULT_USER);
    }
View Full Code Here


  /* (non-Javadoc)
   * @see edu.indiana.vortex2.gpel.WorkflowContext#prepare(edu.indiana.vortex2.WorkflowClient)
   */
  public  void prepare(WorkflowClient client, Workflow workflow)
      throws GSSException, URISyntaxException {
    LeadContextHeader leadContextHeader = new LeadContextHeader(this.topic,
        proxy.getName().toString());

    leadContextHeader.setXRegistryUrl(new URI(
        XBayaConstants.DEFAULT_XREGISTRY_URL.toString() + "?wsdl"));
    leadContextHeader.setGfacUrl(new URI(XBayaConstants.DEFAULT_GFAC_URL
        .toString()
        + "?wsdl"));
    leadContextHeader.setDscUrl(XBayaConstants.DEFAULT_DSC_URL);
    // The followings might overwrite some variables.
    leadContextHeader.setWorkflowTemplateId(workflow.getGPELTemplateID());
    leadContextHeader.setWorkflowInstanceId(new URI(client.getInstanceID()));
    leadContextHeader.setUserDn(proxy.getName().toString());
    leadContextHeader.setMyleadAgentUrl(new URI(
        XBayaConstants.DEFAULT_MYLEAD_AGENT_URL.toString() + "?wsdl"));
    WsaEndpointReference eventSink = WseClientAPI.createEndpointReference(
        XBayaConstants.DEFAULT_BROKER_URL.toString(), topic);
    leadContextHeader.setEventSink(eventSink);
    leadContextHeader.setExperimentId("urn:uuid:"+topic);
    this.header =  leadContextHeader;
  }
View Full Code Here

            correlator = null;

            // pass some headers
            LeadContextHeaderHelper helper = new LeadContextHeaderHelper();
            helper.setXBayaConfiguration(new XBayaConfiguration());
            LeadContextHeader leadContext = helper.getLeadContextHeader();
            leadContext.setWorkflowId(URI
                    .create("http://host/2005/11/09/workflowinstace"));
            leadContext.setNodeId("decoder1");
            leadContext.setTimeStep("5");
            leadContext.setServiceId("decoder-instance-10");

            WSIFClient wclient = WSIFRuntime.newClient(wsdlLoc).addHandler(
                    new StickySoapHeaderHandler("use-lead-header", leadContext))
                    .useAsyncMessaging(correlator).setAsyncResponseTimeoutInMs(
                    33000L); // to simplify testing set to just few
View Full Code Here

  public boolean invoke() throws XBayaException {

    WSIFClient client = invoker.getClient();
    //FIXME: Temporary fix
    if (this.leadContext == null) {
       LeadContextHeader lh = new LeadContextHeader(UUID.randomUUID().toString(), "XBaya-User");
       this.leadContext = lh;
    }
    StickySoapHeaderHandler handler = new StickySoapHeaderHandler(
        "use-lead-header", this.leadContext);
    client.addHandler(handler);
View Full Code Here

  private void setup(WsdlDefinitions definitions) throws XBayaException {

    // Set LEAD context header.
    LeadContextHeaderHelper leadContextHelper = new LeadContextHeaderHelper();
    LeadContextHeader leadContext = leadContextHelper
        .getLeadContextHeader();
    leadContext.setEventSink(this.notifier.getEventSink());
    StickySoapHeaderHandler handler = new StickySoapHeaderHandler(
        "use-lead-header", leadContext);
    leadContext.setServiceId(this.nodeID);
    leadContext.setNodeId(this.nodeID);
    leadContext.setWorkflowId(this.notifier.getWorkflowID());
    leadContext.setTimeStep("1");
//    if(this.configuration != null){
//      leadContext.setMyleadAgentUrl(configuration.getMyLeadAgentURL());
//      leadContext.setXRegistryUrl(configuration.getXRegistryURL());
//    }
   
View Full Code Here

        logger.info(definitions.xmlStringPretty());

        // Create lead context.
        LeadContextHeaderHelper leadContextHelper = new LeadContextHeaderHelper();
        leadContextHelper.setXBayaConfiguration(this.configuration);
        LeadContextHeader leadContext = leadContextHelper
                .getLeadContextHeader();

        URI messageBoxURL = null;
        if (this.configuration.isPullMode()) {
            messageBoxURL = this.configuration.getMessageBoxURL();
View Full Code Here

    public void estWithUserCredential() throws ComponentException, IOException,
            GeneralSecurityException {
        boolean userCred = true;
        GSSCredential proxy = null;
        WsdlDefinitions wsdl = null; // Set WSDL of the workflow.
        LeadContextHeader leadContext = null; // Set the LEAD Context.
        URI messageBoxURL = null; // This one can be null;

        String trustedcerts = System.getProperty("trustedcerts");
        String certskey = System.getProperty("certskey");
View Full Code Here

      throws URISyntaxException {
   
    XBayaConfiguration configuration = engine.getConfiguration();
    Workflow workflow = engine.getWorkflow();
   
    LeadContextHeader leadContext = buildLeadContextHeader(workflow, configuration, engine.getMyLead(),
        monitorConfiguration, nodeId, resourceMapping);
   
    return leadContext;

  }
View Full Code Here

    leadContextHelper.setWorkflowTemplateID(workflow
        .getUniqueWorkflowName());

    leadContextHelper.setMonitorConfiguration(monitorConfiguration);

    LeadContextHeader leadContext = leadContextHelper
        .getLeadContextHeader();
   
    leadContext.setNodeId(nodeId);
   
    leadContext.setTimeStep("1");
    leadContext.setXRegistryUrl(new URI(configuration.getXRegistryURL()
        .toString()
        + "?wsdl"));
   
    if(resourceMapping != null){
      leadContext.setResourceMapping(resourceMapping);
    }
    return leadContext;
  }
View Full Code Here

    GsiInvoker secureInvoker = null;
    secureInvoker = new GsiInvoker(credential, XBayaSecurity
        .getTrustedCertificates());

    try {
      LeadContextHeader defaultLeadHeader = odeClient.getDefaultLeadHeader(workflow, topic,
          credential.getName().toString(), new URI(topic), null, null);
      defaultLeadHeader.setExperimentId(topic);
      LEADWorkflowInvoker invoker = new LEADWorkflowInvoker(wsdl,
          defaultLeadHeader, null, secureInvoker, operationName);
     
      WSIFMessage inputMessage = invoker.getInputMessage();
//      inputMessage.setObjectPart("input", XmlConstants.BUILDER.newFragment("<n1:Run xmlns:n1='http://www.extreme.indiana.edu/xbaya/demok/xsd/'><file1>fds</file1><file2>fsfas</file2></n1:Run>"));
View Full Code Here

TOP

Related Classes of xsul.lead.LeadContextHeader

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.