airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lah...@apache.org
Subject [1/2] git commit: fixing unwanted task creation
Date Tue, 13 May 2014 20:41:55 GMT
Repository: airavata
Updated Branches:
  refs/heads/master 5e6040c61 -> a5e696770


fixing unwanted task creation


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

Branch: refs/heads/master
Commit: b2e3fd98a3c96d90ce04def64939ca7e8f656c2e
Parents: 3ba8cfa
Author: lahiru <lahiru@apache.org>
Authored: Tue May 13 16:41:17 2014 -0400
Committer: lahiru <lahiru@apache.org>
Committed: Tue May 13 16:41:17 2014 -0400

----------------------------------------------------------------------
 .../integration/SingleAppIntegrationTestBase.java        | 11 +++++------
 .../orchestrator/server/OrchestratorServerHandler.java   |  4 ----
 .../orchestrator-core/src/test/resources/gfac-config.xml |  2 +-
 3 files changed, 6 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/b2e3fd98/modules/integration-tests/src/test/java/org/apache/airavata/integration/SingleAppIntegrationTestBase.java
----------------------------------------------------------------------
diff --git a/modules/integration-tests/src/test/java/org/apache/airavata/integration/SingleAppIntegrationTestBase.java
b/modules/integration-tests/src/test/java/org/apache/airavata/integration/SingleAppIntegrationTestBase.java
index e136880..b5f8057 100644
--- a/modules/integration-tests/src/test/java/org/apache/airavata/integration/SingleAppIntegrationTestBase.java
+++ b/modules/integration-tests/src/test/java/org/apache/airavata/integration/SingleAppIntegrationTestBase.java
@@ -50,9 +50,10 @@ public class SingleAppIntegrationTestBase extends AbstractIntegrationTest
{
         Thread monitor = (new Thread() {
             public void run() {
             	long previousUpdateTime=-1;
-                while (true) {
+                ExperimentStatus experimentStatus = null;
+                do {
                     try {
-                    	ExperimentStatus experimentStatus = client.getExperimentStatus(expId);
+                    	experimentStatus = client.getExperimentStatus(expId);
 						if (previousUpdateTime!=experimentStatus.getTimeOfStateChange()) {
 							previousUpdateTime=experimentStatus.getTimeOfStateChange();
 							log.info(expId
@@ -60,14 +61,12 @@ public class SingleAppIntegrationTestBase extends AbstractIntegrationTest
{
 									+ " ["+new Date(previousUpdateTime).toString()+"]");
 							
 						}
-						if (experimentStatus.getExperimentState()==ExperimentState.COMPLETED){
-							break;
-						}
                         Thread.sleep(2000);
                     } catch (Exception e) {
                         log.error("Thread interrupted", e.getMessage());
                     }
-                }
+                    System.out.println(experimentStatus.getExperimentState().toString());
+                }while(!experimentStatus.getExperimentState().equals(ExperimentState.COMPLETED));
             }
         });
         monitor.start();

http://git-wip-us.apache.org/repos/asf/airavata/blob/b2e3fd98/modules/orchestrator/airavata-orchestrator-service/src/main/java/org/apache/airavata/orchestrator/server/OrchestratorServerHandler.java
----------------------------------------------------------------------
diff --git a/modules/orchestrator/airavata-orchestrator-service/src/main/java/org/apache/airavata/orchestrator/server/OrchestratorServerHandler.java
b/modules/orchestrator/airavata-orchestrator-service/src/main/java/org/apache/airavata/orchestrator/server/OrchestratorServerHandler.java
index 1024d1c..6efff4f 100644
--- a/modules/orchestrator/airavata-orchestrator-service/src/main/java/org/apache/airavata/orchestrator/server/OrchestratorServerHandler.java
+++ b/modules/orchestrator/airavata-orchestrator-service/src/main/java/org/apache/airavata/orchestrator/server/OrchestratorServerHandler.java
@@ -82,10 +82,6 @@ public class OrchestratorServerHandler implements OrchestratorService.Iface
{
     public boolean launchExperiment(String experimentId) throws TException {
         //TODO: Write the Orchestrator implementaion
         try {
-            List<TaskDetails> tasks = orchestrator.createTasks(experimentId);
-            if (tasks.size() > 1) {
-                log.info("There are multiple tasks for this experiment, So Orchestrator will
launch multiple Jobs");
-            }
             List<String> ids = registry.getIds(RegistryModelType.WORKFLOW_NODE_DETAIL,WorkflowNodeConstants.EXPERIMENT_ID,experimentId);
             for (String workflowNodeId : ids) {
                 WorkflowNodeDetails workflowNodeDetail = (WorkflowNodeDetails)registry.get(RegistryModelType.WORKFLOW_NODE_DETAIL,
workflowNodeId);

http://git-wip-us.apache.org/repos/asf/airavata/blob/b2e3fd98/modules/orchestrator/orchestrator-core/src/test/resources/gfac-config.xml
----------------------------------------------------------------------
diff --git a/modules/orchestrator/orchestrator-core/src/test/resources/gfac-config.xml b/modules/orchestrator/orchestrator-core/src/test/resources/gfac-config.xml
index 5110374..c773fbd 100644
--- a/modules/orchestrator/orchestrator-core/src/test/resources/gfac-config.xml
+++ b/modules/orchestrator/orchestrator-core/src/test/resources/gfac-config.xml
@@ -9,7 +9,7 @@
     WARRANTIES OR CONDITIONS OF ANY ~ KIND, either express or implied. See the
     License for the ~ specific language governing permissions and limitations
     ~ under the License. -->
-    
+
 <GFac>
     <DaemonHandlers>
         <Handler class="org.apache.airavata.gfac.monitor.handlers.GridPullMonitorHandler"/>


Mime
View raw message