Examples of AiravataAPI


Examples of org.apache.airavata.client.api.AiravataAPI

        } catch (URISyntaxException e) {
            this.engine.getGUI().getErrorWindow().error(ErrorMessages.URL_WRONG, e);
            return;
        }

        AiravataAPI airavataAPI = getAiravataAPI();

//        JCRComponentRegistry registry = null;
//        try {
//            registry = new JCRComponentRegistry(airavataAPI);
//        } catch (Exception e) {
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

    public AiravataAPI getAiravataAPI(){
        try {
            URI regURI = new URI(getRegURL());
            PasswordCallbackImpl passwordCallback = new PasswordCallbackImpl(userName, password);
            AiravataAPI airavataAPI = AiravataAPIFactory.getAPI(regURI, getGateway(), userName, passwordCallback);
            return airavataAPI;
        } catch (URISyntaxException e) {
            e.printStackTrace();
        }catch (AiravataAPIInvocationException e) {
            e.printStackTrace()//To change body of catch statement use File | Settings | File Templates.
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

            this.workflowInterpreterTextField.setText(workflowInterpreterURL.toString());
        } else {
            this.workflowInterpreterTextField.setText(XBayaConstants.DEFAULT_WORKFLOW_INTERPRETER_URL);
        }

        AiravataAPI airavataAPI = config.getAiravataAPI();
        if (null != airavataAPI) {
            this.RegistryTextField.setText(config.getRegistryURL());
        } else {
            this.RegistryTextField.setText(XBayaConstants.REGISTRY_URL.toASCIIString());
        }
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

                    List<WorkflowInput> workflowInputs=new ArrayList<WorkflowInput>();
                    for (int i = 0; i < inputNodes.size(); i++) {
                      InputNode inputNode = inputNodes.get(i);
                      workflowInputs.add(new WorkflowInput(inputNode.getID(), inputNode.getDefaultValue().toString()));
                    }
                    AiravataAPI api = engine.getConfiguration().getAiravataAPI();
                   
                    ExperimentAdvanceOptions options = api.getExecutionManager().createExperimentAdvanceOptions(instanceNameFinal, api.getCurrentUser(), null);
                    if (AmazonCredential.getInstance().getAwsAccessKeyId() != null) {
                        options.getCustomSecuritySettings().getAmazonWSSettings().setAccessKeyId(AmazonCredential.getInstance().getAwsAccessKeyId());
                        options.getCustomSecuritySettings().getAmazonWSSettings().setSecretAccessKey(AmazonCredential.getInstance().getAwsSecretAccessKey());
                    }

                    String experimentId = api.getExecutionManager().runExperiment(api.getWorkflowManager().getWorkflowAsString(workflow), workflowInputs,options);
                    try {
                        WorkflowInterpreterLaunchWindow.this.engine.getMonitor().getConfiguration().setTopic(experimentId);
                        WorkflowInterpreterLaunchWindow.this.engine.getMonitor().start();
                    } catch (MonitorException e1) {
                        WorkflowInterpreterLaunchWindow.this.engine.getGUI().getErrorWindow().error(e1);
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

     *
     * @return
     * @throws RepositoryException
     */
    public Map<String, String> getOGCEWorkflowTemplateList() throws AiravataAPIInvocationException {
        AiravataAPI airavataAPI = connectToRegistry();
        List<Workflow> workflows = airavataAPI.getWorkflowManager().getWorkflows();
        Map<String, String> workflowMap = new HashMap<String, String>();
        for(Workflow workflow : workflows){
            workflowMap.put(workflow.getName(), airavataAPI.getWorkflowManager().getWorkflowAsString(workflow.getName()));
        }
        return workflowMap;
    }
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

     * @throws ComponentException
     * @throws Exception
     */
    public Workflow getOGCEWorkflow(QName workflowTemplateId) throws RepositoryException, GraphException,
            ComponentException, Exception {
        AiravataAPI registry = connectToRegistry();
        String xml = registry.getWorkflowManager().getWorkflowAsString(workflowTemplateId.getLocalPart());
        XmlElement xwf = XMLUtil.stringToXmlElement(xml);
        Workflow workflow = new Workflow(xwf);
        return workflow;
    }
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

                QName workflowQName = new QName(XBayaConstants.OGCE_WORKFLOW_NS, workflowId);

                String workflowAsString = XMLUtil.xmlElementToString(workflow.toXML());
                String owner = this.engine.getConfiguration().getRegistryUserName();

                AiravataAPI registry = this.connectToRegistry();
                if (registry.getWorkflowManager().isWorkflowExists(workflow.getName())){
                registry.getWorkflowManager().updateWorkflow(workflow.getName(), workflowAsString);
              }else{
                registry.getWorkflowManager().saveWorkflow(workflowAsString);
              }
                if (registryPublishingWindow.isMakePublic()){
                 
                  registry.getWorkflowManager().publishWorkflow(workflow.getName());
                }
                registryPublishingWindow.hide();
                return true;
            } catch (Exception e) {
                this.engine.getGUI().getErrorWindow().error(e.getMessage(), e);
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

     * @param workflowTemplateId
     * @throws RepositoryException
     */
    public void deleteOGCEWorkflow(QName workflowTemplateId) throws AiravataAPIInvocationException {
        if (XBayaUtil.acquireJCRRegistry(this.engine)) {
            AiravataAPI registry = connectToRegistry();
            registry.getWorkflowManager().removeWorkflow(workflowTemplateId.getLocalPart());
        }
    }
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

     *
     * @param qname
     * @return
     */
    public Workflow getWorkflow(QName qname) throws AiravataAPIInvocationException {
        AiravataAPI registry = connectToRegistry();
        String xml = registry.getWorkflowManager().getWorkflowAsString(qname.getLocalPart());
        Workflow workflow = null;
        try {
            XmlElement xwf = XMLUtil.stringToXmlElement(xml);
            workflow = new Workflow(xwf);
        } catch (GraphException e) {
View Full Code Here

Examples of org.apache.airavata.client.api.AiravataAPI

 
  public void updateXBayaConfigurationServiceURLs() {
    try {
      if (this.getConfiguration().getAiravataAPI()!=null && this.getConfiguration().getAiravataAPI()!=null){
                AiravataAPI airavataAPI = getConfiguration().getAiravataAPI();
                AiravataManager airavataManager = airavataAPI.getAiravataManager();
//                AiravataRegistry2 registry=this.getConfiguration().getJcrComponentRegistry().getRegistry();
            URI eventingServiceURL = airavataManager.getEventingServiceURL();
        if (eventingServiceURL!=null) {
          this.getConfiguration().setBrokerURL(eventingServiceURL);
          this.getMonitor()
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.