Examples of HpcApplicationDeploymentType


Examples of org.apache.airavata.schemas.gfac.HpcApplicationDeploymentType

        return applicationContext;
    }

    protected ApplicationDescription getApplicationDesc(JobTypeType jobType) {
        ApplicationDescription appDesc = new ApplicationDescription(HpcApplicationDeploymentType.type);
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) appDesc.getType();
        ApplicationDeploymentDescriptionType.ApplicationName name = ApplicationDeploymentDescriptionType.ApplicationName.Factory
                .newInstance();
        name.setStringValue("EchoLocal");
        app.setApplicationName(name);
        ProjectAccountType projectAccountType = app.addNewProjectAccount();
        projectAccountType.setProjectAccountNumber("TG-AST110064");

        QueueType queueType = app.addNewQueue();
        queueType.setQueueName("development");

        app.setCpuCount(1);
        // TODO: also handle parallel jobs
        if ((jobType.enumValue() == JobTypeType.SERIAL) || (jobType.enumValue() == JobTypeType.SINGLE)) {
            app.setJobType(JobTypeType.SERIAL);
        } else if (jobType.enumValue() == JobTypeType.MPI) {
            app.setJobType(JobTypeType.MPI);
        } else {
            app.setJobType(JobTypeType.OPEN_MP);
        }

        app.setNodeCount(1);
        app.setProcessorsPerNode(1);

        /*
         * Use bat file if it is compiled on Windows
         */
        app.setExecutableLocation("/bin/cat");

        /*
         * Default tmp location
         */
        String date = (new Date()).toString();
        date = date.replaceAll(" ", "_");
        date = date.replaceAll(":", "_");

        String remoteTempDir = scratchDir + File.separator + "SimpleEcho" + "_" + date + "_" + UUID.randomUUID();

        System.out.println(remoteTempDir);

        // no need of these parameters, as unicore manages by itself
        app.setScratchWorkingDirectory(remoteTempDir);
        app.setStaticWorkingDirectory(remoteTempDir);
        app.setInputDataDirectory(remoteTempDir + File.separator + "inputData");
        app.setOutputDataDirectory(remoteTempDir + File.separator + "outputData");

        app.setStandardOutput(app.getOutputDataDirectory() + "/jsdl_stdout");

        app.setStandardError(app.getOutputDataDirectory() + "/jsdl_stderr");

        return appDesc;
    }
View Full Code Here

Examples of org.apache.airavata.schemas.gfac.HpcApplicationDeploymentType

        /*
            Application descriptor creation and saving
         */
        ApplicationDescription appDesc = new ApplicationDescription(HpcApplicationDeploymentType.type);
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) appDesc.getType();
        ApplicationDeploymentDescriptionType.ApplicationName name = ApplicationDeploymentDescriptionType.ApplicationName.Factory.newInstance();
        name.setStringValue(serviceName);
        app.setApplicationName(name);
        ProjectAccountType projectAccountType = app.addNewProjectAccount();
        projectAccountType.setProjectAccountNumber("uot111");

        QueueType queueType = app.addNewQueue();
        queueType.setQueueName("normal");

        app.setCpuCount(1);
        app.setJobType(JobTypeType.SERIAL);
        app.setNodeCount(1);
        app.setProcessorsPerNode(1);
        app.setMaxWallTime(10);
        /*
           * Use bat file if it is compiled on Windows
           */
        app.setExecutableLocation("/bin/echo");

        /*
           * Default tmp location
           */
        String tempDir = "/oasis/projects/nsf/uot111/us3/airavata-workdirs/";

        app.setScratchWorkingDirectory(tempDir);
        app.setInstalledParentPath("/opt/torque/bin/");

        try {
            airavataAPI.getApplicationManager().saveApplicationDescription(serviceName, gsiSshHostNameTrestles, appDesc);
        } 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.schemas.gfac.HpcApplicationDeploymentType

        /*
            Application descriptor creation and saving
         */
        ApplicationDescription appDesc = new ApplicationDescription(HpcApplicationDeploymentType.type);
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) appDesc.getType();
        ApplicationDeploymentDescriptionType.ApplicationName name = ApplicationDeploymentDescriptionType.ApplicationName.Factory.newInstance();
        name.setStringValue(serviceName);
        app.setApplicationName(name);
        ProjectAccountType projectAccountType = app.addNewProjectAccount();
        projectAccountType.setProjectAccountNumber("uot111");

        QueueType queueType = app.addNewQueue();
        queueType.setQueueName("normal");

        app.setCpuCount(1);
        app.setJobType(JobTypeType.MPI);
        app.setNodeCount(32);
        app.setProcessorsPerNode(2);
        app.setMaxWallTime(10);
        /*
           * Use bat file if it is compiled on Windows
           */
        app.setExecutableLocation("/home/us3/trestles/bin/us_mpi_analysis");

        /*
           * Default tmp location
           */
        String tempDir = "/oasis/projects/nsf/uot111/us3/airavata-workdirs/";
        app.setScratchWorkingDirectory(tempDir);
        app.setInstalledParentPath("/opt/torque/bin/");
        app.setJobSubmitterCommand("/opt/mvapich2/pgi/ib/bin/mpiexec");
        try {
            airavataAPI.getApplicationManager().saveApplicationDescription(serviceName, gsiSshHostNameTrestles, appDesc);
        } 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.schemas.gfac.HpcApplicationDeploymentType

        /*
            Application descriptor creation and saving
         */
        ApplicationDescription appDesc = new ApplicationDescription(HpcApplicationDeploymentType.type);
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) appDesc.getType();
        ApplicationDeploymentDescriptionType.ApplicationName name = ApplicationDeploymentDescriptionType.ApplicationName.Factory.newInstance();
        name.setStringValue(serviceName);
        app.setApplicationName(name);
        ProjectAccountType projectAccountType = app.addNewProjectAccount();
        projectAccountType.setProjectAccountNumber("TG-MCB070039N");

        QueueType queueType = app.addNewQueue();
        queueType.setQueueName("normal");

        app.setCpuCount(1);
        app.setJobType(JobTypeType.MPI);
        app.setNodeCount(32);
        app.setProcessorsPerNode(2);
        app.setMaxWallTime(10);
        /*
           * Use bat file if it is compiled on Windows
           */
        app.setExecutableLocation("/home1/01623/us3/bin/us_mpi_analysis");

        /*
           * Default tmp location
           */
        String tempDir = "/home1/01623/us3";
        app.setScratchWorkingDirectory(tempDir);
        app.setInstalledParentPath("/usr/bin/");
        app.setJobSubmitterCommand("/usr/local/bin/ibrun");
        try {
            airavataAPI.getApplicationManager().saveApplicationDescription(serviceName, gsiSshHostNameStampede, appDesc);
        } 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.schemas.gfac.HpcApplicationDeploymentType

        /*
           Application descriptor creation and saving
        */
        ApplicationDescription appDesc = new ApplicationDescription(HpcApplicationDeploymentType.type);
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) appDesc.getType();
        ApplicationDeploymentDescriptionType.ApplicationName name = ApplicationDeploymentDescriptionType.ApplicationName.Factory.newInstance();
        name.setStringValue(serviceName);
        app.setApplicationName(name);
        ProjectAccountType projectAccountType = app.addNewProjectAccount();
        projectAccountType.setProjectAccountNumber("TG-MCB070039N");

        QueueType queueType = app.addNewQueue();
        queueType.setQueueName("normal");

        app.setCpuCount(1);
        app.setJobType(JobTypeType.SERIAL);
        app.setNodeCount(1);
        app.setProcessorsPerNode(1);
        app.setMaxWallTime(10);
        /*
        * Use bat file if it is compiled on Windows
        */
        app.setExecutableLocation("/bin/echo");

        /*
        * Default tmp location
        */
        String tempDir = "/home1/01623/us3";
      
        app.setScratchWorkingDirectory(tempDir);
        app.setInstalledParentPath("/usr/bin/");

        try {
            airavataAPI.getApplicationManager().saveApplicationDescription(serviceName, gsiSshHostNameStampede, appDesc);
        } 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.schemas.gfac.HpcApplicationDeploymentType

        log.info("Invoking GSISSH Provider Invoke ...");
        StringBuffer data = new StringBuffer();
        jobExecutionContext.getNotifier().publish(new StartExecutionEvent());
        HostDescriptionType host = jobExecutionContext.getApplicationContext().
                getHostDescription().getType();
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) jobExecutionContext.getApplicationContext().
                getApplicationDeploymentDescription().getType();
        JobDetails jobDetails = new JobDetails();
        try {
            Cluster cluster = null;
            if (jobExecutionContext.getSecurityContext(GSISecurityContext.GSI_SECURITY_CONTEXT) != null) {
View Full Code Here

Examples of org.apache.airavata.schemas.gfac.HpcApplicationDeploymentType

        /*
        * App
        */
        ApplicationDescription appDesc = new ApplicationDescription(HpcApplicationDeploymentType.type);
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) appDesc.getType();
        ApplicationDeploymentDescriptionType.ApplicationName name = ApplicationDeploymentDescriptionType.ApplicationName.Factory.newInstance();
        name.setStringValue("EchoLocal");
        app.setApplicationName(name);
        ProjectAccountType projectAccountType = app.addNewProjectAccount();
        projectAccountType.setProjectAccountNumber("sds128");

        QueueType queueType = app.addNewQueue();
        queueType.setQueueName("normal");

        app.setCpuCount(1);
        app.setJobType(JobTypeType.SERIAL);
        app.setNodeCount(1);
        app.setProcessorsPerNode(1);

        /*
        * Use bat file if it is compiled on Windows
        */
        app.setExecutableLocation("/bin/echo");

        /*
        * Default tmp location
        */
        String tempDir = "/home/ogce/scratch/";
        String date = (new Date()).toString();
        date = date.replaceAll(" ", "_");
        date = date.replaceAll(":", "_");

        tempDir = workingDirectory + File.separator
                + "SimpleEcho" + "_" + date + "_" + UUID.randomUUID();

        System.out.println(tempDir);
        app.setScratchWorkingDirectory(tempDir);
        app.setStaticWorkingDirectory(tempDir);
        app.setInputDataDirectory(tempDir + File.separator + "inputData");
        app.setOutputDataDirectory(tempDir + File.separator + "outputData");
        app.setStandardOutput(tempDir + File.separator + app.getApplicationName().getStringValue() + ".stdout");
        app.setStandardError(tempDir + File.separator + app.getApplicationName().getStringValue() + ".stderr");
        app.setMaxWallTime(5);
        app.setInstalledParentPath("/opt/torque/bin/");

        /*
        * Service
        */
        ServiceDescription serv = new ServiceDescription();
View Full Code Here

Examples of org.apache.airavata.schemas.gfac.HpcApplicationDeploymentType

    public void execute(JobExecutionContext jobExecutionContext) throws GFacProviderException, GFacException {
        log.info("Invoking GSISSH Provider Invoke ...");
        jobExecutionContext.getNotifier().publish(new StartExecutionEvent());
        HostDescriptionType host = jobExecutionContext.getApplicationContext().
                getHostDescription().getType();
        HpcApplicationDeploymentType app = (HpcApplicationDeploymentType) jobExecutionContext.getApplicationContext().
                getApplicationDeploymentDescription().getType();
        JobDetails jobDetails = new JobDetails();
       String taskID = jobExecutionContext.getTaskData().getTaskID();
        try {
            Cluster cluster = null;
View Full Code Here

Examples of org.apache.airavata.schemas.gfac.HpcApplicationDeploymentType

    JobDefinitionDocument jobDefDoc = JobDefinitionDocument.Factory
        .newInstance();
    JobDefinitionType value = jobDefDoc.addNewJobDefinition();

    HpcApplicationDeploymentType appDepType = (HpcApplicationDeploymentType) context
        .getApplicationContext().getApplicationDeploymentDescription()
        .getType();

    // build Identification
    createJobIdentification(value, appDepType);
View Full Code Here

Examples of org.apache.airavata.schemas.gfac.HpcApplicationDeploymentType

    JobDefinitionDocument jobDefDoc = JobDefinitionDocument.Factory
        .newInstance();
    JobDefinitionType value = jobDefDoc.addNewJobDefinition();

    HpcApplicationDeploymentType appDepType = (HpcApplicationDeploymentType) context
        .getApplicationContext().getApplicationDeploymentDescription()
        .getType();

    // build Identification
    createJobIdentification(value, appDepType);
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.