geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dblev...@apache.org
Subject svn commit: r580251 - /geronimo/server/branches/2.0/modules/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java
Date Fri, 28 Sep 2007 08:21:14 GMT
Author: dblevins
Date: Fri Sep 28 01:21:13 2007
New Revision: 580251

URL: http://svn.apache.org/viewvc?rev=580251&view=rev
Log:
Keep going if the workaround has already been applied.  (this code will all be removed once
we know we're done with openejb-3.0-beta-1)

Modified:
    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/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=580251&r1=580250&r2=580251&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
Fri Sep 28 01:21:13 2007
@@ -30,6 +30,7 @@
 import javax.management.ObjectName;
 import javax.naming.NamingException;
 import javax.naming.Context;
+import javax.naming.NameAlreadyBoundException;
 import javax.persistence.EntityManagerFactory;
 import javax.resource.spi.ResourceAdapter;
 import javax.transaction.TransactionManager;
@@ -120,10 +121,13 @@
         configurationFactory = new ConfigurationFactory(offline);
         assembler = new Assembler();
         Context rootContext = assembler.getContainerSystem().getJNDIContext();
-        // Temporary bug fix
-        rootContext.bind("openejb/ejb/.", "");
-        rootContext.bind("openejb/client/.", "");
-        rootContext.bind("openejb/Deployment/.", "");
+        try {
+            // Temporary bug fix
+            rootContext.bind("openejb/ejb/.", "");
+            rootContext.bind("openejb/client/.", "");
+            rootContext.bind("openejb/Deployment/.", "");
+        } catch (NameAlreadyBoundException workaroundAlreadyApplied) {
+        }
 
         // install application server
         ApplicationServer applicationServer = new ServerFederation();



Mime
View raw message