geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ke...@apache.org
Subject svn commit: r570950 - in /geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb: ClientEjbReference.java OpenEjbSystemGBean.java
Date Wed, 29 Aug 2007 22:09:24 GMT
Author: kevan
Date: Wed Aug 29 15:09:23 2007
New Revision: 570950

URL: http://svn.apache.org/viewvc?rev=570950&view=rev
Log:
Merge of 570242 from trunk into branches/2.0. Removed temporary debug statement from EjbRefBuilder
along the way

Modified:
    geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/ClientEjbReference.java
    geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java

Modified: geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/ClientEjbReference.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/ClientEjbReference.java?rev=570950&r1=570949&r2=570950&view=diff
==============================================================================
--- geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/ClientEjbReference.java
(original)
+++ geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/ClientEjbReference.java
Wed Aug 29 15:09:23 2007
@@ -37,6 +37,7 @@
         Properties p = new Properties();
         p.put("java.naming.factory.initial", "org.apache.openejb.client.RemoteInitialContextFactory");
         p.put("java.naming.provider.url", url);
+        p.put("openejb.client.moduleId", "openejb/Deployment");
 
         try {
             InitialContext ctx = new InitialContext(p);

Modified: geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java?rev=570950&r1=570949&r2=570950&view=diff
==============================================================================
--- geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java
(original)
+++ geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java
Wed Aug 29 15:09:23 2007
@@ -104,15 +104,10 @@
         }
         System.setProperty("duct tape","");
         System.setProperty("admin.disabled", "true");
-        SystemInstance systemInstance = SystemInstance.get();
 
-        String format = systemInstance.getProperty("openejb.deploymentId.format");
-        if (format == null){
-            systemInstance.setProperty("openejb.deploymentId.format", "{moduleId}/{ejbName}");
-        }
-
-        systemInstance.setProperty("openejb.jndiname.strategy.class", "org.apache.openejb.assembler.classic.JndiBuilder$TemplatedStrategy");
-        systemInstance.setProperty("openejb.jndiname.format", "{deploymentId}/{interfaceClass}");
+        setDefaultProperty("openejb.deploymentId.format", "{moduleId}/{ejbName}");
+        setDefaultProperty("openejb.jndiname.strategy.class", "org.apache.openejb.assembler.classic.JndiBuilder$TemplatedStrategy");
+        setDefaultProperty("openejb.jndiname.format", "{deploymentId}/{interfaceClass}");
 
         System.setProperty("openejb.naming", "xbean");
         if (transactionManager == null) {
@@ -156,6 +151,16 @@
 
         // process all resource adapters
         processResourceAdapterWrappers(resourceAdapters);
+    }
+
+    private void setDefaultProperty(String key, String value) {
+        SystemInstance systemInstance = SystemInstance.get();
+
+
+        String format = systemInstance.getProperty(key);
+        if (format == null){
+            systemInstance.setProperty(key, value);
+        }
     }
 
     @SuppressWarnings({"unchecked"})



Mime
View raw message