airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lah...@apache.org
Subject svn commit: r1384134 - /incubator/airavata/trunk/modules/workflow-model/workflow-model-core/src/main/java/org/apache/airavata/workflow/model/component/registry/JCRComponentRegistry.java
Date Wed, 12 Sep 2012 21:25:38 GMT
Author: lahiru
Date: Wed Sep 12 21:25:38 2012
New Revision: 1384134

URL: http://svn.apache.org/viewvc?rev=1384134&view=rev
Log:
fixig error during xbaya startup..

Modified:
    incubator/airavata/trunk/modules/workflow-model/workflow-model-core/src/main/java/org/apache/airavata/workflow/model/component/registry/JCRComponentRegistry.java

Modified: incubator/airavata/trunk/modules/workflow-model/workflow-model-core/src/main/java/org/apache/airavata/workflow/model/component/registry/JCRComponentRegistry.java
URL: http://svn.apache.org/viewvc/incubator/airavata/trunk/modules/workflow-model/workflow-model-core/src/main/java/org/apache/airavata/workflow/model/component/registry/JCRComponentRegistry.java?rev=1384134&r1=1384133&r2=1384134&view=diff
==============================================================================
--- incubator/airavata/trunk/modules/workflow-model/workflow-model-core/src/main/java/org/apache/airavata/workflow/model/component/registry/JCRComponentRegistry.java
(original)
+++ incubator/airavata/trunk/modules/workflow-model/workflow-model-core/src/main/java/org/apache/airavata/workflow/model/component/registry/JCRComponentRegistry.java
Wed Sep 12 21:25:38 2012
@@ -55,6 +55,7 @@ public class JCRComponentRegistry extend
         HashMap<String, String> map = new HashMap<String, String>();
         URL configURL = this.getClass().getClassLoader().getResource(REPOSITORY_PROPERTIES);
         Properties properties = new Properties();
+        if(configURL != null){
         try {
             properties.load(configURL.openStream());
             if(properties.get(REGISTRY_USER) != null){
@@ -65,6 +66,10 @@ public class JCRComponentRegistry extend
         } catch (IOException e) {
             e.printStackTrace();  //To change body of catch statement use File | Settings
| File Templates.
         }
+        }else {
+            // provide a way to get gatewayid from xbaya gui
+            properties.setProperty(GATEWAY_ID, "default");
+        }
         try {
             this.registry = AiravataRegistryFactory.getRegistry(new Gateway((String)properties.get(GATEWAY_ID)),
                     new AiravataUser(username));



Mime
View raw message