geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r397017 - in /geronimo/branches/1.1/modules: connector-builder/src/test/org/apache/geronimo/connector/deployment/ j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/ j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/ jetty-bu...
Date Tue, 25 Apr 2006 23:15:42 GMT
Author: djencks
Date: Tue Apr 25 16:15:37 2006
New Revision: 397017

URL: http://svn.apache.org/viewcvs?rev=397017&view=rev
Log:
GERONIMO-1916 port modified ref 371145 from trunk, remove need for openejb classes in all
jndi contexts

Added:
    geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java
      - copied, changed from r391989, geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java
Modified:
    geronimo/branches/1.1/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
    geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EJBReferenceBuilder.java
    geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java
    geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/UnavailableEJBReferenceBuilder.java
    geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java
    geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/MockEJBConfigBuilder.java
    geronimo/branches/1.1/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java
    geronimo/branches/1.1/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java
    geronimo/branches/1.1/modules/naming-builder/src/test/org/apache/geronimo/naming/deployment/MessageDestinationTest.java
    geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/java/ComponentContextBuilder.java
    geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/ORBReference.java
    geronimo/branches/1.1/modules/tomcat-builder/src/test/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilderTest.java

Modified: geronimo/branches/1.1/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
(original)
+++ geronimo/branches/1.1/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/ConnectorModuleBuilderTest.java
Tue Apr 25 16:15:37 2006
@@ -115,10 +115,6 @@
             return null;
         }
 
-        public Object createHandleDelegateReference() {
-            return null;
-        }
-
         public Reference createEJBRemoteRef(String refName, Configuration configuration,
String name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) {
             return null;
         }

Modified: geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EJBReferenceBuilder.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EJBReferenceBuilder.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EJBReferenceBuilder.java
(original)
+++ geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EJBReferenceBuilder.java
Tue Apr 25 16:15:37 2006
@@ -30,13 +30,11 @@
 
 
 /**
- * @version $Rev: 386000 $ $Date$
+ * @version $Rev:390932 $ $Date$
  */
 public interface EJBReferenceBuilder {
 
     Reference createCORBAReference(Configuration configuration, AbstractNameQuery containerNameQuery,
URI nsCorbaloc, String objectName, String home) throws DeploymentException;
-
-    Object createHandleDelegateReference() throws DeploymentException;
 
     Reference createEJBRemoteRef(String refName, Configuration configuration, String name,
String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery query,
boolean isSession, String home, String remote) throws DeploymentException;
 

Modified: geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java
(original)
+++ geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java
Tue Apr 25 16:15:37 2006
@@ -65,9 +65,6 @@
         return ejbReferenceBuilder.createCORBAReference(configuration, cssNameQuery, nsCorbaloc,
objectName, home);
     }
 
-    public Object getHandleDelegateReference() throws DeploymentException {
-        return ejbReferenceBuilder.createHandleDelegateReference();
-    }
     public Reference getEJBRemoteRef(String refName, Configuration configuration, String
name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) throws DeploymentException {
         return ejbReferenceBuilder.createEJBRemoteRef(refName, configuration, name, requiredModule,
 optionalModule, targetConfigId, query, isSession, home, remote);
     }

Modified: geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/UnavailableEJBReferenceBuilder.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/UnavailableEJBReferenceBuilder.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/UnavailableEJBReferenceBuilder.java
(original)
+++ geronimo/branches/1.1/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/UnavailableEJBReferenceBuilder.java
Tue Apr 25 16:15:37 2006
@@ -36,10 +36,6 @@
         throw new DeploymentException("EJB references are unavailable in this configuration");
     }
 
-    public Object createHandleDelegateReference() throws DeploymentException {
-        return null;
-    }
-
     public Reference createEJBRemoteRef(String refName, Configuration configuration, String
name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) throws DeploymentException {
         throw new DeploymentException("EJB references are unavailable in this configuration");
     }

Modified: geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java
(original)
+++ geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java
Tue Apr 25 16:15:37 2006
@@ -245,10 +245,6 @@
             return new FakeReference(objectName);
         }
 
-        public Object createHandleDelegateReference() {
-            return null;
-        }
-
         public Reference createEJBRemoteRef(String refName, Configuration configuration,
String name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) throws DeploymentException {
             return null;
         }

Modified: geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/MockEJBConfigBuilder.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/MockEJBConfigBuilder.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/MockEJBConfigBuilder.java
(original)
+++ geronimo/branches/1.1/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/MockEJBConfigBuilder.java
Tue Apr 25 16:15:37 2006
@@ -88,10 +88,6 @@
         return null;
     }
 
-    public Object createHandleDelegateReference() {
-        return null;
-    }
-
     public Reference createEJBRemoteRef(String refName, Configuration configuration, String
name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) throws DeploymentException {
         return null;
     }

Modified: geronimo/branches/1.1/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java
(original)
+++ geronimo/branches/1.1/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java
Tue Apr 25 16:15:37 2006
@@ -165,10 +165,6 @@
                         return null;
                     }
 
-                    public Object createHandleDelegateReference() {
-                        return null;
-                    }
-
                     public Reference createEJBRemoteRef(String refName, Configuration configuration,
String name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) {
                         return null;
                     }

Modified: geronimo/branches/1.1/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java
(original)
+++ geronimo/branches/1.1/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java
Tue Apr 25 16:15:37 2006
@@ -659,11 +659,7 @@
         AbstractNameQuery corbaGBean = earContext.getCORBAGBeanObjectName();
         if (corbaGBean != null) {
             builder.addORB(earConfiguration.getId(), corbaGBean);
-        }
-
-        Object handleDelegateReference = refContext.getHandleDelegateReference();
-        if (handleDelegateReference != null) {
-            builder.addHandleDelegateReference(handleDelegateReference);
+            builder.addHandleDelegateReference(earConfiguration.getId(), corbaGBean);
         }
 
         URI moduleURI = module.getModuleURI();

Modified: geronimo/branches/1.1/modules/naming-builder/src/test/org/apache/geronimo/naming/deployment/MessageDestinationTest.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/naming-builder/src/test/org/apache/geronimo/naming/deployment/MessageDestinationTest.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/naming-builder/src/test/org/apache/geronimo/naming/deployment/MessageDestinationTest.java
(original)
+++ geronimo/branches/1.1/modules/naming-builder/src/test/org/apache/geronimo/naming/deployment/MessageDestinationTest.java
Tue Apr 25 16:15:37 2006
@@ -56,10 +56,6 @@
             return null;
         }
 
-        public Object createHandleDelegateReference() {
-            return null;
-        }
-
         public Reference createEJBRemoteRef(String refName, Configuration configuration,
String name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) {
             return null;
         }

Modified: geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/java/ComponentContextBuilder.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/java/ComponentContextBuilder.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/java/ComponentContextBuilder.java
(original)
+++ geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/java/ComponentContextBuilder.java
Tue Apr 25 16:15:37 2006
@@ -21,6 +21,7 @@
 import org.apache.geronimo.kernel.repository.Artifact;
 import org.apache.geronimo.naming.reference.KernelReference;
 import org.apache.geronimo.naming.reference.ORBReference;
+import org.apache.geronimo.naming.reference.HandleDelegateReference;
 
 import javax.naming.NamingException;
 import javax.transaction.UserTransaction;
@@ -48,8 +49,8 @@
         context.put("ORB", new ORBReference(configId, corbaGBeanObjectName));
     }
 
-    public void addHandleDelegateReference(Object handleDelegateReference) {
-        context.put("HandleDelegate", handleDelegateReference);
+    public void addHandleDelegateReference(Artifact configId, AbstractNameQuery corbaGBeanNameQuery)
{
+        context.put("HandleDelegate", new HandleDelegateReference(configId, corbaGBeanNameQuery));
     }
 
     public void bind(String name, Object value) {

Copied: geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java
(from r391989, geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java)
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java?p2=geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java&p1=geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java&r1=391989&r2=397017&rev=397017&view=diff
==============================================================================
--- geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java
(original)
+++ geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/HandleDelegateReference.java
Tue Apr 25 16:15:37 2006
@@ -21,15 +21,17 @@
 import javax.naming.NamingException;
 
 import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.kernel.repository.Artifact;
+import org.apache.geronimo.gbean.AbstractNameQuery;
+import org.apache.geronimo.gbean.AbstractName;
 
 /**
  * @version $Rev: 356097 $ $Date: 2005-12-11 17:29:03 -0800 (Sun, 11 Dec 2005) $
  */
-public class HandleDelegateReference extends SimpleAwareReference {
-    private final ObjectName corbaGBean;
+public class HandleDelegateReference extends ConfigurationAwareReference {
 
-    public HandleDelegateReference(ObjectName corbaGBean) {
-        this.corbaGBean = corbaGBean;
+    public HandleDelegateReference(Artifact configId, AbstractNameQuery abstractNameQuery)
{
+        super(configId, abstractNameQuery);
     }
 
     public String getClassName() {
@@ -39,9 +41,10 @@
     public Object getContent() throws NamingException {
         Kernel kernel = getKernel();
         try {
-            return kernel.getAttribute(corbaGBean, "handleDelegate");
+            AbstractName targetName = resolveTargetName();
+            return kernel.getAttribute(targetName, "handleDelegate");
         } catch (Exception e) {
-            throw (NameNotFoundException) new NameNotFoundException("Error getting ORB attribut
from CORBAGBean: objectName=" + corbaGBean).initCause(e);
+            throw (NameNotFoundException) new NameNotFoundException("Error getting handle
delegate attribute from CORBAGBean: name query =" + abstractNameQuery).initCause(e);
         }
     }
 }

Modified: geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/ORBReference.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/ORBReference.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/ORBReference.java
(original)
+++ geronimo/branches/1.1/modules/naming/src/java/org/apache/geronimo/naming/reference/ORBReference.java
Tue Apr 25 16:15:37 2006
@@ -43,7 +43,7 @@
             AbstractName targetName = resolveTargetName();
             return kernel.getAttribute(targetName, "ORB");
         } catch (Exception e) {
-            throw (NameNotFoundException) new NameNotFoundException("Error getting ORB attribut
from CORBAGBean: name query =" + abstractNameQuery).initCause(e);
+            throw (NameNotFoundException) new NameNotFoundException("Error getting ORB attribute
from CORBAGBean: name query =" + abstractNameQuery).initCause(e);
         }
     }
 }

Modified: geronimo/branches/1.1/modules/tomcat-builder/src/test/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilderTest.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/tomcat-builder/src/test/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilderTest.java?rev=397017&r1=397016&r2=397017&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/tomcat-builder/src/test/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilderTest.java
(original)
+++ geronimo/branches/1.1/modules/tomcat-builder/src/test/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilderTest.java
Tue Apr 25 16:15:37 2006
@@ -194,10 +194,6 @@
                         return null;
                     }
 
-                    public Object createHandleDelegateReference() {
-                        return null;
-                    }
-
                     public Reference createEJBRemoteRef(String refName, Configuration configuration,
String name, String requiredModule, String optionalModule, Artifact targetConfigId, AbstractNameQuery
query, boolean isSession, String home, String remote) {
                         return null;
                     }



Mime
View raw message