airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chath...@apache.org
Subject airavata git commit: make process fail if task fails
Date Wed, 16 Sep 2015 19:40:41 GMT
Repository: airavata
Updated Branches:
  refs/heads/master 3d0dd11de -> 719d1a7eb


make process fail if task fails


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

Branch: refs/heads/master
Commit: 719d1a7eb7307bbb38f5829d0bc6d7acafc19513
Parents: 3d0dd11
Author: Chathuri Wimalasena <chathuri@apache.org>
Authored: Wed Sep 16 15:40:32 2015 -0400
Committer: Chathuri Wimalasena <chathuri@apache.org>
Committed: Wed Sep 16 15:40:32 2015 -0400

----------------------------------------------------------------------
 .../main/java/org/apache/airavata/gfac/impl/GFacEngineImpl.java   | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/719d1a7e/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/GFacEngineImpl.java
----------------------------------------------------------------------
diff --git a/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/GFacEngineImpl.java
b/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/GFacEngineImpl.java
index 86b2d87..ff1ec8b 100644
--- a/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/GFacEngineImpl.java
+++ b/modules/gfac/gfac-impl/src/main/java/org/apache/airavata/gfac/impl/GFacEngineImpl.java
@@ -206,6 +206,7 @@ public class GFacEngineImpl implements GFacEngine {
             ProcessStatus processStatus = processContext.getProcessStatus();
             processStatus.setTimeOfStateChange(AiravataUtils.getCurrentTimestamp().getTime());
             processStatus.setReason(errorMsg);
+            processStatus.setState(ProcessState.FAILED);
             processContext.setProcessStatus(processStatus);
             GFacUtils.saveAndPublishProcessStatus(processContext);
 			throw new GFacException("Job submission task failed");
@@ -264,6 +265,7 @@ public class GFacEngineImpl implements GFacEngine {
                             ProcessStatus processStatus = processContext.getProcessStatus();
                             processStatus.setTimeOfStateChange(AiravataUtils.getCurrentTimestamp().getTime());
                             processStatus.setReason(errorMsg);
+                            processStatus.setState(ProcessState.FAILED);
                             processContext.setProcessStatus(processStatus);
                             GFacUtils.saveAndPublishProcessStatus(processContext);
 							throw new GFacException("Error while staging input data");
@@ -434,6 +436,7 @@ public class GFacEngineImpl implements GFacEngine {
                         ProcessStatus processStatus = processContext.getProcessStatus();
                         processStatus.setTimeOfStateChange(AiravataUtils.getCurrentTimestamp().getTime());
                         processStatus.setReason(errorMsg);
+                        processStatus.setState(ProcessState.FAILED);
                         processContext.setProcessStatus(processStatus);
                         GFacUtils.saveAndPublishProcessStatus(processContext);
 						throw new GFacException("Error while staging output data");


Mime
View raw message