airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ramin...@apache.org
Subject [1/2] airavata git commit: Added check for zookeper object null. AIRAVATA-1661
Date Tue, 28 Apr 2015 19:30:36 GMT
Repository: airavata
Updated Branches:
  refs/heads/master 2527fe8a0 -> 135607c74


Added check for zookeper object null. AIRAVATA-1661

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

Branch: refs/heads/master
Commit: e8a6a6e3ade44effbd9438cb6526e8d0cf28b420
Parents: 1fba5f9
Author: raminder <raminder@apache.org>
Authored: Tue Apr 28 15:29:33 2015 -0400
Committer: raminder <raminder@apache.org>
Committed: Tue Apr 28 15:29:33 2015 -0400

----------------------------------------------------------------------
 .../airavata/orchestrator/server/OrchestratorServerHandler.java   | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/e8a6a6e3/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 06dafb6..b5626a6 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
@@ -512,6 +512,9 @@ public class OrchestratorServerHandler implements OrchestratorService.Iface,
         try {
             Experiment experiment = (Experiment) registry.get(
                     RegistryModelType.EXPERIMENT, experimentId);
+            if (zk == null || !zk.getState().isConnected()){
+                zk = new ZooKeeper(AiravataZKUtils.getZKhostPort(), AiravataZKUtils.getZKTimeout(),this);
+            }
             if (experiment == null) {
                 log.errorId(experimentId, "Error retrieving the Experiment by the given experimentID:
{}.", experimentId);
                 throw new OrchestratorException("Error retrieving the Experiment by the given
experimentID: " + experimentId);


Mime
View raw message