fixing AIRAVATA-1741

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

Branch: refs/heads/0.15-release-branch
Commit: c0d62c56bfc04d37d08ee021d017b4b30afc77fc
Parents: a411b2b
Author: Supun Nakandala <[email protected]>
Authored: Tue Jun 30 21:51:53 2015 +0530
Committer: Supun Nakandala <[email protected]>
Committed: Tue Jun 30 21:51:53 2015 +0530

----------------------------------------------------------------------
 app/libraries/ExperimentUtilities.php | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/blob/c0d62c56/app/libraries/ExperimentUtilities.php
----------------------------------------------------------------------
diff --git a/app/libraries/ExperimentUtilities.php 
b/app/libraries/ExperimentUtilities.php
index 2343df0..f74a05b 100644
--- a/app/libraries/ExperimentUtilities.php
+++ b/app/libraries/ExperimentUtilities.php
@@ -616,7 +616,12 @@ class ExperimentUtilities
             $userConfigData = $experiment->userConfigurationData;
             $scheduling = $userConfigData->computationalResourceScheduling;
             $expVal['scheduling'] = $scheduling;
-            $expVal["computeResource"] = 
CRUtilities::get_compute_resource($scheduling->resourceHostId);
+            try {
+                $expVal["computeResource"] = 
CRUtilities::get_compute_resource($scheduling->resourceHostId);
+            } catch (Exception $ex) {
+                //Error while retrieving CR
+                $expVal["computeResource"] = "";
+            }
         }
         $expVal["applicationInterface"] = 
AppUtilities::get_application_interface($experiment->applicationId);
 

Reply via email to