airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chath...@apache.org
Subject airavata git commit: adding more changes to test framework AIRAVATA-1652
Date Tue, 07 Apr 2015 18:12:22 GMT
Repository: airavata
Updated Branches:
  refs/heads/master 97bd7a77a -> 05bb24d9e


adding more changes to test framework AIRAVATA-1652


Project: http://git-wip-us.apache.org/repos/asf/airavata/repo
Commit: http://git-wip-us.apache.org/repos/asf/airavata/commit/05bb24d9
Tree: http://git-wip-us.apache.org/repos/asf/airavata/tree/05bb24d9
Diff: http://git-wip-us.apache.org/repos/asf/airavata/diff/05bb24d9

Branch: refs/heads/master
Commit: 05bb24d9eb46bbe0327312dcadcdf5731caba12f
Parents: 97bd7a7
Author: Chathuri Wimalasena <kamalasini@gmail.com>
Authored: Tue Apr 7 14:12:18 2015 -0400
Committer: Chathuri Wimalasena <kamalasini@gmail.com>
Committed: Tue Apr 7 14:12:18 2015 -0400

----------------------------------------------------------------------
 .../ApplicationRegister.java                    |  26 ++-
 .../ComputeResourceRegister.java                |   4 +-
 .../ExperimentExecution.java                    | 233 ++++++++++++-------
 .../FrameworkBootstrapping.java                 |  13 +-
 .../utils/TestFrameworkConstants.java           |   4 +-
 .../main/resources/airavata-client.properties   |   4 +-
 .../main/resources/test-framework.properties    |  18 +-
 7 files changed, 184 insertions(+), 118 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/05bb24d9/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ApplicationRegister.java
----------------------------------------------------------------------
diff --git a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ApplicationRegister.java
b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ApplicationRegister.java
index 06f6343..fa87d83 100644
--- a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ApplicationRegister.java
+++ b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ApplicationRegister.java
@@ -127,25 +127,25 @@ public class ApplicationRegister {
         appModules.add(amberModuleId);
 
         InputDataObjectType input1 = createAppInput("Heat_Restart_File", null,
-                DataType.URI, null, 1, true, true,false, "Heating up the system equilibration
stage - 02_Heat.rst", null);
+                DataType.URI, "-c", 1, true, true,false, "Heating up the system equilibration
stage - 02_Heat.rst", null);
 
         InputDataObjectType input2 = createAppInput("Production_Control_File", null,
-                DataType.URI, null, 2, true, true, false, "Constant pressure and temperature
for production stage - 03_Prod.in", null);
+                DataType.URI, "-i ", 2, true, true, false, "Constant pressure and temperature
for production stage - 03_Prod.in", null);
 
         InputDataObjectType input3 = createAppInput("Parameter_Topology_File", null,
-                DataType.URI, null, 3, true, true, false, "Parameter and Topology coordinates
- prmtop", null);
+                DataType.URI, "-p", 3, true, true, false, "Parameter and Topology coordinates
- prmtop", null);
 
         List<InputDataObjectType> applicationInputs = new ArrayList<InputDataObjectType>();
         applicationInputs.add(input1);
         applicationInputs.add(input2);
         applicationInputs.add(input3);
 
-        OutputDataObjectType output1 = createAppOutput("AMBER_Execution_Summary", "03_Prod.info",
DataType.URI, true, true);
-        OutputDataObjectType output2 = createAppOutput("AMBER_Execution_log", "03_Prod.out",
DataType.URI, true, true);
-        OutputDataObjectType output3 = createAppOutput("AMBER_Trajectory_file", "03_Prod.mdcrd",
DataType.URI, true, true);
-        OutputDataObjectType output4 = createAppOutput("AMBER_Restart_file", "03_Prod.rst",
DataType.URI, true, true);
-        OutputDataObjectType output5 = createAppOutput("STDOUT", null, DataType.STDOUT, true,
false);
-        OutputDataObjectType output6 = createAppOutput("STDERR", null, DataType.STDERR, true,
false);
+        OutputDataObjectType output1 = createAppOutput("AMBER_Execution_Summary", "03_Prod.info",
DataType.URI, true, true, "-inf");
+        OutputDataObjectType output2 = createAppOutput("AMBER_Execution_log", "03_Prod.out",
DataType.URI, true, true, "-o");
+        OutputDataObjectType output3 = createAppOutput("AMBER_Trajectory_file", "03_Prod.mdcrd",
DataType.URI, true, true, "-x");
+        OutputDataObjectType output4 = createAppOutput("AMBER_Restart_file", "03_Prod.rst",
DataType.URI, true, true, " -r");
+        OutputDataObjectType output5 = createAppOutput("STDOUT", null, DataType.STDOUT, true,
false, null);
+        OutputDataObjectType output6 = createAppOutput("STDERR", null, DataType.STDERR, true,
false, null);
         List<OutputDataObjectType> applicationOutputs = new ArrayList<OutputDataObjectType>();
         applicationOutputs.add(output1);
         applicationOutputs.add(output2);
@@ -171,8 +171,8 @@ public class ApplicationRegister {
         List<InputDataObjectType> applicationInputs = new ArrayList<InputDataObjectType>();
         applicationInputs.add(input1);
 
-        OutputDataObjectType output1 = createAppOutput("STDOUT", null, DataType.STDOUT, true,
false);
-        OutputDataObjectType output2 = createAppOutput("STDERR", null, DataType.STDERR, true,
false);
+        OutputDataObjectType output1 = createAppOutput("STDOUT", null, DataType.STDOUT, true,
false, null);
+        OutputDataObjectType output2 = createAppOutput("STDERR", null, DataType.STDERR, true,
false, null);
         List<OutputDataObjectType> applicationOutputs = new ArrayList<OutputDataObjectType>();
         applicationOutputs.add(output1);
         applicationOutputs.add(output2);
@@ -282,13 +282,15 @@ public class ApplicationRegister {
                                                        String value,
                                                        DataType type,
                                                        boolean isRequired,
-                                                       boolean requiredToCMD) {
+                                                       boolean requiredToCMD,
+                                                       String argument) {
         OutputDataObjectType outputDataObjectType = new OutputDataObjectType();
         if (inputName != null) outputDataObjectType.setName(inputName);
         if (value != null) outputDataObjectType.setValue(value);
         if (type != null) outputDataObjectType.setType(type);
         outputDataObjectType.setIsRequired(isRequired);
         outputDataObjectType.setRequiredToAddedToCommandLine(requiredToCMD);
+        outputDataObjectType.setApplicationArgument(argument);
         return outputDataObjectType;
     }
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/05bb24d9/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ComputeResourceRegister.java
----------------------------------------------------------------------
diff --git a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ComputeResourceRegister.java
b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ComputeResourceRegister.java
index c17f073..ebb1451 100644
--- a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ComputeResourceRegister.java
+++ b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ComputeResourceRegister.java
@@ -99,12 +99,12 @@ public class ComputeResourceRegister {
                 if (resourceName.contains("stampede")) {
                     // adding stampede
                     stampedeResourceId = registerComputeHost(resourceName, "TACC Stampede
Cluster",
-                            ResourceJobManagerType.SLURM, "push", "/usr/bin", SecurityProtocol.SSH_KEYS,
22, null);
+                            ResourceJobManagerType.SLURM, "push", "/usr/bin", SecurityProtocol.SSH_KEYS,
22, "ibrun");
                     System.out.println("Stampede Resource Id is " + stampedeResourceId);
                 } else if (resourceName.contains("trestles")) {
                     //Register Trestles
                     trestlesResourceId = registerComputeHost("trestles.sdsc.xsede.org", "SDSC
Trestles Cluster",
-                            ResourceJobManagerType.PBS, "push", "/opt/torque/bin/", SecurityProtocol.SSH_KEYS,
22, null);
+                            ResourceJobManagerType.PBS, "push", "/opt/torque/bin/", SecurityProtocol.SSH_KEYS,
22, "mpirun -np");
                     System.out.println("Trestles Resource Id is " + trestlesResourceId);
                 } else if (resourceName.contains("bigred2")) {
                     //Register BigRedII

http://git-wip-us.apache.org/repos/asf/airavata/blob/05bb24d9/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ExperimentExecution.java
----------------------------------------------------------------------
diff --git a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ExperimentExecution.java
b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ExperimentExecution.java
index 16a2d88..1f71908 100644
--- a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ExperimentExecution.java
+++ b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/ExperimentExecution.java
@@ -37,10 +37,7 @@ import org.apache.airavata.model.messaging.event.JobStatusChangeEvent;
 import org.apache.airavata.model.messaging.event.MessageType;
 import org.apache.airavata.model.util.ExperimentModelUtil;
 import org.apache.airavata.model.workspace.Project;
-import org.apache.airavata.model.workspace.experiment.ComputationalResourceScheduling;
-import org.apache.airavata.model.workspace.experiment.Experiment;
-import org.apache.airavata.model.workspace.experiment.ExperimentState;
-import org.apache.airavata.model.workspace.experiment.UserConfigurationData;
+import org.apache.airavata.model.workspace.experiment.*;
 import org.apache.airavata.testsuite.multitenantedairavata.utils.PropertyFileType;
 import org.apache.airavata.testsuite.multitenantedairavata.utils.PropertyReader;
 import org.apache.airavata.testsuite.multitenantedairavata.utils.TestFrameworkConstants;
@@ -49,10 +46,11 @@ import org.apache.thrift.TException;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import java.io.File;
+import java.io.PrintWriter;
+import java.text.DateFormat;
+import java.text.SimpleDateFormat;
+import java.util.*;
 
 public class ExperimentExecution {
     private Airavata.Client airavata;
@@ -63,9 +61,10 @@ public class ExperimentExecution {
     private Map<String, Map<String, String>> appInterfaceMap;
     private Map<String, List<Project>> projectsMap;
     private PropertyReader propertyReader;
+    private PrintWriter resultWriter;
 
     public ExperimentExecution(Airavata.Client airavata,
-                               Map<String, String> tokenMap ) {
+                               Map<String, String> tokenMap ) throws Exception {
         this.airavata = airavata;
         this.csTokens = tokenMap;
         this.appInterfaceMap = getApplicationMap(tokenMap);
@@ -73,9 +72,23 @@ public class ExperimentExecution {
         this.projectsMap = getProjects(tokenMap);
         this.experimentsWithTokens = new HashMap<String, String>();
         this.experimentsWithGateway = new HashMap<String, String>();
+        String resultFileLocation = propertyReader.readProperty(TestFrameworkConstants.FrameworkPropertiesConstants.RESULT_WRITE_LOCATION,
PropertyFileType.TEST_FRAMEWORK);
+        String resultFileName = getResultFileName();
+        File resultFile = new File(resultFileLocation + resultFileName);
+        resultWriter = new PrintWriter(resultFile, "UTF-8");
+        resultWriter.println("Test Framework Results");
+        resultWriter.println("========================================");
     }
 
-    protected Map<String, Map<String, String>> getApplicationMap (Map<String,
String> tokenMap){
+    public PrintWriter getResultWriter() {
+        return resultWriter;
+    }
+
+    public void setResultWriter(PrintWriter resultWriter) {
+        this.resultWriter = resultWriter;
+    }
+
+    protected Map<String, Map<String, String>> getApplicationMap (Map<String,
String> tokenMap) throws  Exception{
         appInterfaceMap = new HashMap<String, Map<String, String>>();
         try {
             if (tokenMap != null && !tokenMap.isEmpty()){
@@ -85,18 +98,22 @@ public class ExperimentExecution {
                 }
             }
         } catch (AiravataSystemException e) {
-            e.printStackTrace();
+            logger.error("Error while getting application interfaces", e);
+            throw new Exception("Error while getting application interfaces", e);
         } catch (InvalidRequestException e) {
-            e.printStackTrace();
+            logger.error("Error while getting application interfaces", e);
+            throw new Exception("Error while getting application interfaces", e);
         } catch (AiravataClientException e) {
-            e.printStackTrace();
+            logger.error("Error while getting application interfaces", e);
+            throw new Exception("Error while getting application interfaces", e);
         } catch (TException e) {
-            e.printStackTrace();
+            logger.error("Error while getting application interfaces", e);
+            throw new Exception("Error while getting application interfaces", e);
         }
         return appInterfaceMap;
     }
 
-    protected Map<String, List<Project>> getProjects (Map<String, String>
tokenMap){
+    protected Map<String, List<Project>> getProjects (Map<String, String>
tokenMap) throws Exception{
         projectsMap = new HashMap<String, List<Project>>();
         try {
             if (tokenMap != null && !tokenMap.isEmpty()){
@@ -109,13 +126,17 @@ public class ExperimentExecution {
                 }
             }
         } catch (AiravataSystemException e) {
-            e.printStackTrace();
+            logger.error("Error while getting all user projects", e);
+            throw new Exception("Error while getting all user projects", e);
         } catch (InvalidRequestException e) {
-            e.printStackTrace();
+            logger.error("Error while getting all user projects", e);
+            throw new Exception("Error while getting all user projects", e);
         } catch (AiravataClientException e) {
-            e.printStackTrace();
+            logger.error("Error while getting all user projects", e);
+            throw new Exception("Error while getting all user projects", e);
         } catch (TException e) {
-            e.printStackTrace();
+            logger.error("Error while getting all user projects", e);
+            throw new Exception("Error while getting all user projects", e);
         }
         return projectsMap;
     }
@@ -132,69 +153,107 @@ public class ExperimentExecution {
     }
 
     public void monitorExperiments () throws Exception {
+
         String brokerUrl = propertyReader.readProperty(TestFrameworkConstants.AiravataClientConstants.RABBIT_BROKER_URL,
PropertyFileType.AIRAVATA_CLIENT);
         System.out.println("broker url " + brokerUrl);
         final String exchangeName = propertyReader.readProperty(TestFrameworkConstants.AiravataClientConstants.RABBIT_EXCHANGE_NAME,
PropertyFileType.AIRAVATA_CLIENT);
         RabbitMQStatusConsumer consumer = new RabbitMQStatusConsumer(brokerUrl, exchangeName);
-        for (final String expId : experimentsWithGateway.keySet()){
-            final String gatewayId = experimentsWithGateway.get(expId);
-            consumer.listen(new MessageHandler() {
-                @Override
-                public Map<String, Object> getProperties() {
-                    Map<String, Object> props = new HashMap<String, Object>();
-                    List<String> routingKeys = new ArrayList<String>();
+
+        consumer.listen(new MessageHandler() {
+            @Override
+            public Map<String, Object> getProperties() {
+                Map<String, Object> props = new HashMap<String, Object>();
+                List<String> routingKeys = new ArrayList<String>();
+                for (String expId : experimentsWithGateway.keySet()) {
+                    String gatewayId = experimentsWithGateway.get(expId);
+                    System.out.println("experiment Id : " + expId + " gateway Id : " + gatewayId);
+
                     routingKeys.add(gatewayId);
                     routingKeys.add(gatewayId + "." + expId);
                     routingKeys.add(gatewayId + "." + expId + ".*");
                     routingKeys.add(gatewayId + "." + expId + ".*.*");
                     routingKeys.add(gatewayId + "." + expId + ".*.*.*");
-
-                    props.put(MessagingConstants.RABBIT_ROUTING_KEY, routingKeys);
-                    return props;
                 }
+                props.put(MessagingConstants.RABBIT_ROUTING_KEY, routingKeys);
+                return props;
+            }
 
-                @Override
-                public void onMessage(MessageContext message) {
+            @Override
+            public void onMessage(MessageContext message) {
 
-                    if (message.getType().equals(MessageType.EXPERIMENT)){
-                        try {
-                            ExperimentStatusChangeEvent event = new ExperimentStatusChangeEvent();
-                            TBase messageEvent = message.getEvent();
-                            byte[] bytes = ThriftUtils.serializeThriftObject(messageEvent);
-                            ThriftUtils.createThriftFromBytes(bytes, event);
-                            ExperimentState expState = event.getState();
-                            if (expState.equals(ExperimentState.COMPLETED)){
-                                // check file transfers
-                                List<OutputDataObjectType> experimentOutputs = airavata.getExperimentOutputs(expId);
-                                int i = 1;
-                                for (OutputDataObjectType output : experimentOutputs){
-                                    logger.info("################ Experiment : " + expId
+ " COMPLETES ###################");
-                                    logger.info("Output " + i + " : "  + output.getValue());
-                                    i++;
-                                }
+                if (message.getType().equals(MessageType.EXPERIMENT)) {
+                    try {
+                        ExperimentStatusChangeEvent event = new ExperimentStatusChangeEvent();
+                        TBase messageEvent = message.getEvent();
+                        byte[] bytes = ThriftUtils.serializeThriftObject(messageEvent);
+                        ThriftUtils.createThriftFromBytes(bytes, event);
+                        ExperimentState expState = event.getState();
+                        String expId = event.getExperimentId();
+                        String gatewayId = event.getGatewayId();
+
+                        if (expState.equals(ExperimentState.COMPLETED)) {
+                            resultWriter.println();
+                            resultWriter.println("Results for experiment : " + expId + "
of gateway Id : " + gatewayId);
+                            resultWriter.println("=====================================================================");
+                            resultWriter.println("Status : " + ExperimentState.COMPLETED.toString());
+                            // check file transfers
+                            List<OutputDataObjectType> experimentOutputs = airavata.getExperimentOutputs(expId);
+                            int i = 1;
+                            for (OutputDataObjectType output : experimentOutputs) {
+
+                                System.out.println("################ Experiment : " + expId
+ " COMPLETES ###################");
+                                System.out.println("Output " + i + " : " + output.getValue());
+                                resultWriter.println("Output " + i + " : " + output.getValue());
+                                i++;
                             }
-                            logger.info(" Experiment Id : '" + expId
-                                    + "' with state : '" + event.getState().toString() +
-                                    " for Gateway " + event.getGatewayId());
-                        } catch (TException e) {
-                            logger.error(e.getMessage(), e);
-                        }
-                    }else if (message.getType().equals(MessageType.JOB)){
-                        try {
-                            JobStatusChangeEvent event = new JobStatusChangeEvent();
-                            TBase messageEvent = message.getEvent();
-                            byte[] bytes = ThriftUtils.serializeThriftObject(messageEvent);
-                            ThriftUtils.createThriftFromBytes(bytes, event);
-                            logger.info(" Job ID : '" + event.getJobIdentity().getJobId()
-                                    + "' with state : '" + event.getState().toString() +
-                                    " for Gateway " + event.getJobIdentity().getGatewayId());
-                        } catch (TException e) {
-                            logger.error(e.getMessage(), e);
+                            resultWriter.println("################  End of Results for Experiment
: " + expId + " ###############");
+                            resultWriter.println();
+                        } else if (expState.equals(ExperimentState.FAILED)) {
+                            // check file transfers
+                            int j = 1;
+                            resultWriter.println("Status : " + ExperimentState.FAILED.toString());
+                            System.out.println("################ Experiment : " + expId +
" FAILED ###################");
+                            Experiment experiment = airavata.getExperiment(expId);
+                            List<ErrorDetails> errors = experiment.getErrors();
+                            for (ErrorDetails errorDetails : errors) {
+                                System.out.println(errorDetails.getActualErrorMessage());
+                                resultWriter.println("Actual Error : " + j + " : " + errorDetails.getActualErrorMessage());
+                                resultWriter.println("User Friendly Message : " + j + " :
" + errorDetails.getUserFriendlyMessage());
+                                resultWriter.println("Corrective Action : " + j + " : " +
errorDetails.getCorrectiveAction());
+                            }
+                            resultWriter.println("################  End of Results for Experiment
: " + expId + " ###############");
                         }
+                        System.out.println(" Experiment Id : '" + expId
+                                + "' with state : '" + event.getState().toString() +
+                                " for Gateway " + event.getGatewayId());
+                    } catch (TException e) {
+                        e.printStackTrace();
+                        logger.error(e.getMessage(), e);
+                    }
+                } else if (message.getType().equals(MessageType.JOB)) {
+                    try {
+                        JobStatusChangeEvent event = new JobStatusChangeEvent();
+                        TBase messageEvent = message.getEvent();
+                        byte[] bytes = ThriftUtils.serializeThriftObject(messageEvent);
+                        ThriftUtils.createThriftFromBytes(bytes, event);
+                        System.out.println(" Job ID : '" + event.getJobIdentity().getJobId()
+                                + "' with state : '" + event.getState().toString() +
+                                " for Gateway " + event.getJobIdentity().getGatewayId());
+//                        resultWriter.println("Job Status : " + event.getState().toString());
+
+                    } catch (TException e) {
+                        logger.error(e.getMessage(), e);
                     }
                 }
-            });
-        }
+            resultWriter.flush();
+            }
+        });
+    }
+
+    private String getResultFileName (){
+        DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd_HHmmss");
+        Calendar cal = Calendar.getInstance();
+        return dateFormat.format(cal.getTime());
     }
 
     public void createAmberExperiment () throws Exception{
@@ -255,17 +314,18 @@ public class ExperimentExecution {
                                     experimentId = airavata.createExperiment(gatewayId, simpleExperiment);
                                     experimentsWithTokens.put(experimentId, token);
                                     experimentsWithGateway.put(experimentId, gatewayId);
-                                }else if (resourceName.equals(TestFrameworkConstants.AppcatalogConstants.BR2_RESOURCE_NAME))
{
-                                    ComputationalResourceScheduling scheduling = ExperimentModelUtil.createComputationResourceScheduling(id,
4, 1, 1, "normal", 20, 0, 1, null);
-                                    UserConfigurationData userConfigurationData = new UserConfigurationData();
-                                    userConfigurationData.setAiravataAutoSchedule(false);
-                                    userConfigurationData.setOverrideManualScheduledParams(false);
-                                    userConfigurationData.setComputationalResourceScheduling(scheduling);
-                                    simpleExperiment.setUserConfigurationData(userConfigurationData);
-                                    experimentId = airavata.createExperiment(gatewayId, simpleExperiment);
-                                    experimentsWithTokens.put(experimentId, token);
-                                    experimentsWithGateway.put(experimentId, gatewayId);
                                 }
+//                                else if (resourceName.equals(TestFrameworkConstants.AppcatalogConstants.BR2_RESOURCE_NAME))
{
+//                                    ComputationalResourceScheduling scheduling = ExperimentModelUtil.createComputationResourceScheduling(id,
4, 1, 1, "normal", 20, 0, 1, null);
+//                                    UserConfigurationData userConfigurationData = new UserConfigurationData();
+//                                    userConfigurationData.setAiravataAutoSchedule(false);
+//                                    userConfigurationData.setOverrideManualScheduledParams(false);
+//                                    userConfigurationData.setComputationalResourceScheduling(scheduling);
+//                                    simpleExperiment.setUserConfigurationData(userConfigurationData);
+//                                    experimentId = airavata.createExperiment(gatewayId,
simpleExperiment);
+//                                    experimentsWithTokens.put(experimentId, token);
+//                                    experimentsWithGateway.put(experimentId, gatewayId);
+//                                }
                             }
                         }
                     }
@@ -327,17 +387,18 @@ public class ExperimentExecution {
                                         experimentId = airavata.createExperiment(gatewayId,
simpleExperiment);
                                         experimentsWithTokens.put(experimentId, token);
                                         experimentsWithGateway.put(experimentId, gatewayId);
-                                    } else if (resourceName.equals(TestFrameworkConstants.AppcatalogConstants.BR2_RESOURCE_NAME))
{
-                                        ComputationalResourceScheduling scheduling = ExperimentModelUtil.createComputationResourceScheduling(id,
4, 1, 1, "normal", 20, 0, 1, null);
-                                        UserConfigurationData userConfigurationData = new
UserConfigurationData();
-                                        userConfigurationData.setAiravataAutoSchedule(false);
-                                        userConfigurationData.setOverrideManualScheduledParams(false);
-                                        userConfigurationData.setComputationalResourceScheduling(scheduling);
-                                        simpleExperiment.setUserConfigurationData(userConfigurationData);
-                                        experimentId = airavata.createExperiment(gatewayId,
simpleExperiment);
-                                        experimentsWithTokens.put(experimentId, token);
-                                        experimentsWithGateway.put(experimentId, gatewayId);
                                     }
+//                                    else if (resourceName.equals(TestFrameworkConstants.AppcatalogConstants.BR2_RESOURCE_NAME))
{
+//                                        ComputationalResourceScheduling scheduling = ExperimentModelUtil.createComputationResourceScheduling(id,
4, 1, 1, "normal", 20, 0, 1, null);
+//                                        UserConfigurationData userConfigurationData = new
UserConfigurationData();
+//                                        userConfigurationData.setAiravataAutoSchedule(false);
+//                                        userConfigurationData.setOverrideManualScheduledParams(false);
+//                                        userConfigurationData.setComputationalResourceScheduling(scheduling);
+//                                        simpleExperiment.setUserConfigurationData(userConfigurationData);
+//                                        experimentId = airavata.createExperiment(gatewayId,
simpleExperiment);
+//                                        experimentsWithTokens.put(experimentId, token);
+//                                        experimentsWithGateway.put(experimentId, gatewayId);
+//                                    }
                                 }
                             }
                         }

http://git-wip-us.apache.org/repos/asf/airavata/blob/05bb24d9/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/FrameworkBootstrapping.java
----------------------------------------------------------------------
diff --git a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/FrameworkBootstrapping.java
b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/FrameworkBootstrapping.java
index 93811a6..cff569a 100644
--- a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/FrameworkBootstrapping.java
+++ b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/FrameworkBootstrapping.java
@@ -28,10 +28,7 @@ import org.apache.commons.cli.*;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.InputStreamReader;
+import java.io.*;
 import java.util.HashMap;
 import java.util.Map;
 
@@ -79,9 +76,13 @@ public class FrameworkBootstrapping {
                 tokens = readTokens();
                 experimentExecution = new ExperimentExecution(setup.getAiravata(), tokens);
                 experimentExecution.createEchoExperiment();
-//                experimentExecution.createAmberExperiment();
+                experimentExecution.createAmberExperiment();
                 experimentExecution.launchExperiments();
-//                experimentExecution.monitorExperiments();
+                experimentExecution.monitorExperiments();
+//                PrintWriter resultWriter = experimentExecution.getResultWriter();
+//                resultWriter.println("End of test framework results");
+//                resultWriter.println("======================================");
+//                resultWriter.flush();
             }
         } catch (Exception e) {
             logger.error("Error occured while set up", e);

http://git-wip-us.apache.org/repos/asf/airavata/blob/05bb24d9/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/utils/TestFrameworkConstants.java
----------------------------------------------------------------------
diff --git a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/utils/TestFrameworkConstants.java
b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/utils/TestFrameworkConstants.java
index 93991cd..35cc6d1 100644
--- a/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/utils/TestFrameworkConstants.java
+++ b/modules/test-suite/multi-tenanted-airavata/src/main/java/org/apache/airavata/testsuite/multitenantedairavata/utils/TestFrameworkConstants.java
@@ -47,6 +47,7 @@ public class TestFrameworkConstants {
         public static final String SSH_PWD = "ssh.password";
         public static final String SSH_USERNAME = "ssh.username";
         public static final String TOKEN_WRITE_LOCATION = "token.file.location";
+        public static final String RESULT_WRITE_LOCATION = "result.file.location";
     }
 
     public static final class GatewayConstants {
@@ -89,9 +90,6 @@ public class TestFrameworkConstants {
         public static final String AMBER_HEAT_RST_LOCATION = "02_Heat.rst_location";
         public static final String AMBER_PROD_IN_LOCATION = "03_Prod.in_location";
         public static final String AMBER_PRMTOP_LOCATION = "prmtop_location";
-
-
-
     }
 
     public static final class CredentialStoreConstants {

http://git-wip-us.apache.org/repos/asf/airavata/blob/05bb24d9/modules/test-suite/multi-tenanted-airavata/src/main/resources/airavata-client.properties
----------------------------------------------------------------------
diff --git a/modules/test-suite/multi-tenanted-airavata/src/main/resources/airavata-client.properties
b/modules/test-suite/multi-tenanted-airavata/src/main/resources/airavata-client.properties
index c44bd1f..8e79d9b 100644
--- a/modules/test-suite/multi-tenanted-airavata/src/main/resources/airavata-client.properties
+++ b/modules/test-suite/multi-tenanted-airavata/src/main/resources/airavata-client.properties
@@ -39,10 +39,10 @@ thrift.server.port=8930
 credential.store.keystore.url=/Users/chathuri/dev/airavata/credential-store/oa4mp/airavata_sym.jks
 credential.store.keystore.alias=airavata
 credential.store.keystore.password=airavata
-credential.store.jdbc.url=jdbc:derby://localhost:1527/experiment_catalog;create=true;user=airavata;password=airavata
+credential.store.jdbc.url=jdbc:mysql://localhost:3306/experiment_catalog
 credential.store.jdbc.user=airavata
 credential.store.jdbc.password=airavata
-credential.store.jdbc.driver=org.apache.derby.jdbc.ClientDriver
+credential.store.jdbc.driver=com.mysql.jdbc.Driver
 
 
 ######################################################################

http://git-wip-us.apache.org/repos/asf/airavata/blob/05bb24d9/modules/test-suite/multi-tenanted-airavata/src/main/resources/test-framework.properties
----------------------------------------------------------------------
diff --git a/modules/test-suite/multi-tenanted-airavata/src/main/resources/test-framework.properties
b/modules/test-suite/multi-tenanted-airavata/src/main/resources/test-framework.properties
index fe83905..3a66eb1 100644
--- a/modules/test-suite/multi-tenanted-airavata/src/main/resources/test-framework.properties
+++ b/modules/test-suite/multi-tenanted-airavata/src/main/resources/test-framework.properties
@@ -20,19 +20,23 @@
 
 # Test environment related properties
 numberof.gateways=10
+generic.gateway.name=testGateway
+generic.gateway.domain=.airavata.org
 users.per.gateway=10
 compute.resoure.list=trestles.sdsc.xsede.org,stampede.tacc.xsede.org,bigred2.uits.iu.edu
 login.usernames=ogce,ogce,cgateway
 application.list=amber_sander,echo
-ssh.pub.key.location=ssh_key_location
-ssh.private.key.location=ssh_key_location
-ssh.password=pwd
-ssh.username=username
+ssh.pub.key.location=/Users/chathuri/.ssh/id_dsa.pub
+ssh.private.key.location=/Users/chathuri/.ssh/id_dsa
+ssh.password=
+ssh.username=ogce
+token.file.location=/tmp/
+result.file.location=/tmp/test_framework_results/
 
 # Application Inputs
 # Amber input file locations
-02_Heat.rst_location=/a/b/c/02_Heat.rst
-03_Prod.in_location=/a/b/c/03_Prod.in
-prmtop_location=/a/b/c/prmtop
+02_Heat.rst_location=/Users/chathuri/dev/airavata/source/php/inputs/AMBER_FILES/02_Heat.rst
+03_Prod.in_location=/Users/chathuri/dev/airavata/source/php/inputs/AMBER_FILES/03_Prod.in
+prmtop_location=/Users/chathuri/dev/airavata/source/php/inputs/AMBER_FILES/prmtop
 
 


Mime
View raw message