Package org.apache.airavata.model.appcatalog.appdeployment

Examples of org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule$ApplicationModuleTupleSchemeFactory


        SCPDataMovement scpDataMovement = new SCPDataMovement();
        scpDataMovement.setSecurityProtocol(SecurityProtocol.GSI);
        scpDataMovement.setSshPort(22);
        client.addSCPDataMovementDetails(host.getComputeResourceId(), 1, scpDataMovement);

        ApplicationModule amodule = DocumentCreatorUtils.createApplicationModule("Amber", "12.0", null);
        amodule.setAppModuleId(client.registerApplicationModule(amodule));


        ApplicationInterfaceDescription application = new ApplicationInterfaceDescription();
        application.setApplicationName("AmberTrestles");
        application.addToApplicationModules(amodule.getAppModuleId());
        application.addToApplicationInputs(DocumentCreatorUtils.createAppInput("AMBER_HEAT_RST", "AMBER_HEAT_RST", null, null, DataType.URI));
        application.addToApplicationInputs(DocumentCreatorUtils.createAppInput("AMBER_PROD_IN", "AMBER_PROD_IN", null, null, DataType.URI));
        application.addToApplicationInputs(DocumentCreatorUtils.createAppInput("AMBER_PRMTOP", "AMBER_PRMTOP", null, null, DataType.URI));
        application.addToApplicationOutputs(DocumentCreatorUtils.createAppOutput("AMBER_Prod.info", null, DataType.URI));
        application.addToApplicationOutputs(DocumentCreatorUtils.createAppOutput("AMBER_Prod.mdcrd", null, DataType.URI));
        application.addToApplicationOutputs(DocumentCreatorUtils.createAppOutput("AMBER_Prod.out", null, DataType.URI));
        application.addToApplicationOutputs(DocumentCreatorUtils.createAppOutput("AMBER_Prod.rst", null, DataType.URI));
        application.setApplicationInterfaceId(client.registerApplicationInterface(application));

        ApplicationDeploymentDescription deployment = DocumentCreatorUtils.createApplicationDeployment(host.getComputeResourceId(), amodule.getAppModuleId(), "/home/ogce/production/app_wrappers/amber_wrapper.sh", ApplicationParallelismType.SERIAL, "AmberStampede");
        deployment.setAppDeploymentId(client.registerApplicationDeployment(deployment));

        client.addGatewayComputeResourcePreference(getGatewayResourceProfile().getGatewayID(), host.getComputeResourceId(), DocumentCreatorUtils.createComputeResourcePreference(host.getComputeResourceId(), "/oasis/scratch/trestles/ogce/temp_project/", "sds128", false, null, null, null));

View Full Code Here


            if (appInterface.isApplicationInterfaceExists(appID)){
                ainterface = appInterface.getApplicationInterface(appID);
                System.out.println("********** application name ************* : " + ainterface.getApplicationName());
                System.out.println("********** application description ************* : " + ainterface.getApplicationDesription());
            }
            ApplicationModule wrfModule = appInterface.getApplicationModule(wrfModuleId);
            System.out.println("********** WRF module name ************* : " + wrfModule.getAppModuleName());
            ApplicationModule amberModule = appInterface.getApplicationModule(amberModuleId);
            System.out.println("********** Amber module name ************* : " + amberModule.getAppModuleName());

            List<InputDataObjectType> applicationInputs = appInterface.getApplicationInputs(appID);
            System.out.println("********** App Input size ************* : " + applicationInputs.size());

            List<OutputDataObjectType> applicationOutputs = appInterface.getApplicationOutputs(appID);
View Full Code Here

    }

    public String addAppModule (String moduleName){
        try {
            ApplicationModule module = new ApplicationModule();
            module.setAppModuleName(moduleName);
            module.setAppModuleVersion("1.0.0");
            module.setAppModuleDescription("WeatherForcast");
            return appcatalog.getApplicationInterface().addApplicationModule(module);
        } catch (AppCatalogException e) {
            e.printStackTrace();
        }
        return null;
View Full Code Here

        ComputeResourceDescription cm = new ComputeResourceDescription();
        cm.setHostName("localhost");
        cm.setResourceDescription("test compute host");
        String hostId = computeRs.addComputeResource(cm);

        ApplicationModule module = new ApplicationModule();
        module.setAppModuleName("WRF");
        module.setAppModuleVersion("1.0.0");
        String wrfModuleId = appInt.addApplicationModule(module);

        ApplicationDeploymentDescription description = new ApplicationDeploymentDescription();
        description.setAppModuleId(wrfModuleId);
        description.setComputeHostId(hostId);
View Full Code Here

//        resource.setResourceJobManager(submission.getResourceJobManager().toString());
//        return resource;
//    }

    public static ApplicationModule getApplicationModuleDesc (AppModuleResource resource){
        ApplicationModule module = new ApplicationModule();
        module.setAppModuleId(resource.getModuleId());
        module.setAppModuleDescription(resource.getModuleDesc());
        module.setAppModuleName(resource.getModuleName());
        module.setAppModuleVersion(resource.getModuleVersion());
        return module;
    }
View Full Code Here

        return deployment;
    }

    public static ApplicationModule createApplicationModule(String appModuleName,
                                                            String appModuleVersion, String appModuleDescription) {
        ApplicationModule module = new ApplicationModule();
        module.setAppModuleDescription(appModuleDescription);
        module.setAppModuleName(appModuleName);
        module.setAppModuleVersion(appModuleVersion);
        return module;
    }
View Full Code Here

        }
    }

    public static void getAppModule (Airavata.Client client, String moduleId){
        try {
            ApplicationModule applicationModule = client.getApplicationModule(moduleId);
            if (applicationModule != null){
                System.out.println("module name :" + applicationModule.getAppModuleName());
                System.out.println("module version :" + applicationModule.getAppModuleVersion());
            }
        } catch (AiravataSystemException e) {
            e.printStackTrace();
        } catch (InvalidRequestException e) {
            e.printStackTrace();
View Full Code Here

    return deployment;
  }

  public static ApplicationModule createApplicationModule(String appModuleName,
      String appModuleVersion, String appModuleDescription) {
    ApplicationModule module = new ApplicationModule();
    module.setAppModuleDescription(appModuleDescription);
    module.setAppModuleName(appModuleName);
    module.setAppModuleVersion(appModuleVersion);
    return module;
  }
View Full Code Here

TOP

Related Classes of org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule$ApplicationModuleTupleSchemeFactory

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.