Examples of AiravataAPI


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

    }

    private void deleteServiceDescription(JTree tree) throws Exception {
        if (askQuestion("Applications",
                "Are you sure that you want to remove all applications defined in this registry?")) {
            AiravataAPI registry = getRegistry();
            List<ServiceDescription> descriptions = getServiceDescriptions().getDescriptions();
            for (ServiceDescription descriptionWrap : descriptions) {
                registry.getApplicationManager().deleteServiceDescription(descriptionWrap.getType().getName());
            }
            refresh();
            reloadTreeNode(tree, this);
        }
    }
View Full Code Here

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

    }

    private void deleteHostDescription(JTree tree) throws Exception {
        if (askQuestion("Host descriptions",
                "Are you sure that you want to remove all host descriptions in this registry?")) {
            AiravataAPI registry = getRegistry();
            List<HostDescription> descriptions = getHostDescriptions().getDescriptions();
            for (HostDescription descriptionWrap : descriptions) {
                registry.getApplicationManager().removeHostDescriptor(descriptionWrap.getType().getHostName());
            }
            refresh();
            reloadTreeNode(tree, this);
        }
    }
View Full Code Here

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

    }

    private void deleteApplicationDescription(JTree tree) throws Exception {
        if (askQuestion("Application descriptions",
                "Are you sure that you want to remove all application descriptions in this registry?")) {
            AiravataAPI airavataAPI = getRegistry();
            List<ApplicationDeploymentDescriptionWrap> descriptions = getApplicationDeploymentDescriptions()
                    .getDescriptions();
            for (ApplicationDeploymentDescriptionWrap descriptionWrap : descriptions) {
                airavataAPI.getApplicationManager().removeApplicationDescriptor(descriptionWrap.getService(), descriptionWrap.getHost(),
                        descriptionWrap.getDescription().getType().getApplicationName().getStringValue());
            }
            refresh();
            reloadTreeNode(tree, this);
        }
View Full Code Here

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

    private static Logger log = LoggerFactory.getLogger(SchedulerImpl.class+
            "." + WorkflowContextHeaderBuilder.getCurrentContextHeader().getWorkflowMonitoringContext().getExperimentId());

    public Provider schedule(InvocationContext context) throws SchedulerException {

        AiravataAPI registryService = context.getExecutionContext().getRegistryService();

        /*
         * Load Service
         */
        ServiceDescription serviceDesc = null;
        try {
            serviceDesc = registryService.getApplicationManager().getServiceDescription(context.getServiceName());
        } catch (AiravataAPIInvocationException e2) {
            e2.printStackTrace();
        }

        if (serviceDesc == null)
            throw new SchedulerException("Service Desciption for " + context.getServiceName()
                    + " does not found on resource Catalog " + registryService);

        /*
         * Load host
         */
        HostDescription host = scheduleToHost(registryService, context.getServiceName());

        if (host == null)
            throw new SchedulerException("Host Desciption for " + context.getServiceName()
                    + " does not found on resource Catalog " + registryService);

        /*
         * Load app
         */
        ApplicationDescription app = null;
        try {
            app = registryService.getApplicationManager().getApplicationDescription(context.getServiceName(),
                    getRegisteredHost(registryService, context.getServiceName()).getType().getHostName());
        } catch (AiravataAPIInvocationException e2) {
            e2.printStackTrace();
        }

View Full Code Here

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

                    runner = new PredicatedTaskRunner(provenanceWriterThreadPoolSize);
                    try {
                            List<HostDescription> hostList = getDefinedHostDescriptions();
                            for(HostDescription host:hostList){
                                // This will avoid the changes user is doing to one of the predefined Hosts during a restart of the system
                                AiravataAPI registry = getAiravataAPI();
                if(!registry.getApplicationManager().isHostDescriptorExists(host.getType().getHostName())){
                                    log.debug("Saving the predefined Host: " + host.getType().getHostName());
                                    registry.getApplicationManager().addHostDescription(host);
                                }
                            }
                    } catch (AiravataAPIInvocationException e) {
                        e.printStackTrace();
                    } catch (DescriptorRecordAlreadyExistsException e) {
View Full Code Here

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

        } catch (URISyntaxException e1) {
            throw new WorkflowRuntimeException(e1);
        }
        WorkflowInterpretorEventListener listener = null;
        WorkflowInterpreter interpreter = null;
        AiravataAPI airavataAPI = AiravataAPIFactory.getAPI(gatewayId, username);
    WorkflowInterpreterConfiguration workflowInterpreterConfiguration = new WorkflowInterpreterConfiguration(workflow,topic,conf.getMessageBoxURL(), conf.getBrokerURL(), airavataAPI, conf, null, null);
        workflowInterpreterConfiguration.setGfacEmbeddedMode(gfacEmbeddedMode);
        workflowInterpreterConfiguration.setActOnProvenance(provenance);
        // WorkflowInterpreter object should create prior creation of Listener, because listener needs the threadlocal variable
        interpreter = new WorkflowInterpreter(workflowInterpreterConfiguration, new SSWorkflowInterpreterInteractorImpl());
View Full Code Here

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

  }

    public void shutDown(ConfigurationContext configctx, AxisService service) {
        URI gfacURL = (URI) configctx.getProperty(SERVICE_URL);
        if (getAiravataAPI() != null && thread != null) {
            AiravataAPI registry = getAiravataAPI();
            try {
                registry.getAiravataManager().removeWorkflowInterpreterURI(gfacURL);
            } catch (AiravataAPIInvocationException e) {
                e.printStackTrace();
            }
            thread.interrupt();
            try {
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

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

      ComponentRegistry componentRegistry=(ComponentRegistry)o;
      if (observableRegistry!=null){
        observableRegistry.deleteObserver(this);
      }
      if (componentRegistry instanceof JCRComponentRegistry){
        AiravataAPI registry = ((JCRComponentRegistry)componentRegistry).getAiravataAPI();
        if (registry!=null && registry instanceof Observable){
          (observableRegistry=(Observable)registry).addObserver(this);
        }
      }
      load(componentRegistry);
View Full Code Here

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

  private static final String JCR_REGISTRY = "registry";
  private Thread thread;
   
    public void shutDown(ConfigurationContext configurationcontext, AxisService axisservice) {
        logger.info("Message box shutting down");
        AiravataAPI registry = (AiravataAPI) configurationcontext.getProperty(JCR_REGISTRY);
        if (registry != null && thread != null) {
            try {
                registry.getAiravataManager().unsetMessageBoxURI();
            } catch (AiravataAPIInvocationException e) {
                e.printStackTrace();
            }
            thread.interrupt();
            try {
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.