The EJB jars under the root have references to the non-EJB jars under APP-INF/lib in their META-INF/MANIFEST.MF files.

I guess that's not correct. What's the best way to organize my EAR file?

Everything in my EAR is an EJB. No JSPs, war files or any web tier constructs.

Everything follows the following rough organization:
Code1.jar
Code2.jar
EJB.jar (dependent on Code1.jar & Code2.jar)

Do I need to package all the dependencies within each EJB jar?

--
Jimmy Wan
Senior Technical Lead
21st Century Technologies, Inc.
4515 Seton Center Parkway Suite 320
Austin, TX 78759

URL: http://www.21technologies.com

The information in this email and in any attachments is confidential and may be privileged. If you are not the intended recipient, please destroy this message, delete any copies held on your systems and notify the sender immediately. You should not retain, copy or use this email for any purpose, nor disclose all or any part of its content to any other person.


"Aaron Mulder" <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]

08/22/2006 19:22

Please respond to
[email protected]

To
[email protected]
cc
Subject
Re: Deployment Question for Geronimo 1.1





Geronimo doesn't have any special handling for "APP-INF/lib".  How are
you attempting to get the stuff in there on the application's class
path?

Thanks,
    Aaron

On 8/22/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
>
> I thought I didn't need any of the geronimo specific XML files unless I'm creating customized deployment plans?
>
> Now that I've fixed my build to properly include ejb-jar.xml, I'm getting the exception below. Note that this is not a class that should be provided by the container.
>
>
>
> java.lang.NoClassDefFoundError: <interface referenced by some of my EJB jars, that is present in a JAR in the APP-INF/lib directory>
>         at java.lang.ClassLoader.defineClass0(Native Method)
>         at java.lang.ClassLoader.defineClass(ClassLoader.java:539)
>         at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
>         at org.apache.geronimo.kernel.classloader.JarFileClassLoader.access$200(JarFileClassLoader.java:51)
>         at org.apache.geronimo.kernel.classloader.JarFileClassLoader$6.run(JarFileClassLoader.java:275)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at org.apache.geronimo.kernel.classloader.JarFileClassLoader.findClass(JarFileClassLoader.java:227)
>         at org.apache.geronimo.kernel.config.MultiParentClassLoader.loadClass(MultiParentClassLoader.java:243)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
>         at org.apache.geronimo.naming.deployment.ENCConfigBuilder.assureInterface(ENCConfigBuilder.java:622)
>         at org.apache.geronimo.naming.deployment.ENCConfigBuilder.assureEJBObjectInterface(ENCConfigBuilder.java:601)
>         at org.openejb.deployment.SessionBuilder.initContext(SessionBuilder.java:403)
>         at org.openejb.deployment.OpenEJBModuleBuilder.initContext(OpenEJBModuleBuilder.java:343)
>         at org.openejb.deployment.OpenEJBModuleBuilder$$FastClassByCGLIB$$11bd7b20.invoke(<generated>)
>
>         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:53)
>         at org.apache.geronimo.gbean.runtime.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
>         at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:122)
>         at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:817)
>         at org.apache.geronimo.gbean.runtime.RawInvoker.invoke(RawInvoker.java:57)
>         at org.apache.geronimo.kernel.basic.RawOperationInvoker.invoke(RawOperationInvoker.java:35)
>         at org.apache.geronimo.kernel.basic.ProxyMethodInterceptor.intercept(ProxyMethodInterceptor.java:96)
>
>         at org.apache.geronimo.j2ee.deployment.ModuleBuilder$$EnhancerByCGLIB$$f8d4cdc8.initContext(<generated>)
>         at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:500)
>
>         at org.apache.geronimo.j2ee.deployment.EARConfigBuilder$$FastClassByCGLIB$$38e56ec6.invoke(<generated>)
>         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:53)
>         at org.apache.geronimo.gbean.runtime.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
>         at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:122)
>         at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:817)
>         at org.apache.geronimo.gbean.runtime.RawInvoker.invoke(RawInvoker.java:57)
>         at org.apache.geronimo.kernel.basic.RawOperationInvoker.invoke(RawOperationInvoker.java:35)
>         at org.apache.geronimo.kernel.basic.ProxyMethodInterceptor.intercept(ProxyMethodInterceptor.java:96)
>
>         at org.apache.geronimo.deployment.ConfigurationBuilder$$EnhancerByCGLIB$$4c1d63a.buildConfiguration(<generated>)
>         at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:302)
>
>         at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:124)
>         at org.apache.geronimo.deployment.Deployer$$FastClassByCGLIB$$734a235d.invoke(<generated>)
>         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:53)
>         at org.apache.geronimo.gbean.runtime.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
>         at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:122)
>         at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:852)
>         at org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:239)
>         at org.apache.geronimo.deployment.plugin.local.AbstractDeployCommand.doDeploy(AbstractDeployCommand.java:106)
>         at org.apache.geronimo.deployment.plugin.local.DistributeCommand.run(DistributeCommand.java:60)
>         at java.lang.Thread.run(Thread.java:534)
>
>
>
> --
>  Jimmy Wan
>  Senior Technical Lead
>
>  21st Century Technologies, Inc.
>  4515 Seton Center Parkway Suite 320
>  Austin, TX 78759
>
>  URL: http://www.21technologies.com
>
>
>
> The information in this email and in any attachments is confidential and may be privileged. If you are not the intended recipient, please destroy this message, delete any copies held on your systems and notify the sender immediately. You should not retain, copy or use this email for any purpose, nor disclose all or any part of its content to any other person.
>
>
>
>
>
> "Dale de los Reyes" <[EMAIL PROTECTED]>
>
>
>
> 08/22/2006 12:34
>
>
> Please respond to
>  [email protected]
>
>
> To [email protected]
>
> cc
>
>
> Subject RE: Deployment Question for Geronimo 1.1
>
>
>
>
>
>
>
>
> Hello Jimmy,
>
>  At first glance, your .ear file seems to be missing the
>  geronimo-application.xml plan. I'm pretty sure you'll need this to declare
>  your application to Geronimo. As for the EJBs, those will need descriptor
>  files too (both ejb-jar.xml and openejb-jar.xml).
>
>  The user manual for Geronimo 1.1 now has example code available. The link
>  below is for the Bank demo.
>
>  http://cwiki.apache.org/GMOxDOC11/ejb-sample-application.html
>
>  Regards,
>  Dale
>
>
>  >From: [EMAIL PROTECTED]
>  >Reply-To: [email protected]
>  >To: [email protected]
>  >Subject: Deployment Question for Geronimo 1.1
>  >Date: Tue, 22 Aug 2006 12:00:11 -0500
>  >
>  >I'm getting the following error in my geronimo.out when I try to deploy my
>  >EAR.
>  >Deployer operation failed: Module was not an EJB: MyEJB.jar
>  >org.apache.geronimo.common.DeploymentException: Module was not an EJB:
>  >MyEJB.jar
>  >
>  >         at
>  >org.apache.geronimo.j2ee.deployment.EARConfigBuilder.addModules(EARConfigBuilder.java:761)
>  >         at
>  >org.apache.geronimo.j2ee.deployment.EARConfigBuilder.getEarPlan(EARConfigBuilder.java:364)
>  >         at
>  >org.apache.geronimo.j2ee.deployment.EARConfigBuilder.getDeploymentPlan(EARConfigBuilder.java:263)
>  >         at
>  >org.apache.geronimo.j2ee.deployment.EARConfigBuilder$$FastClassByCGLIB$$38e56ec6.invoke(<generated>)
>  >         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:53)
>  >         at
>  >org.apache.geronimo.gbean.runtime.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
>  >         at
>  >org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:122)
>  >         at
>  >org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:817)
>  >         at
>  >org.apache.geronimo.gbean.runtime.RawInvoker.invoke(RawInvoker.java:57)
>  >         at
>  >org.apache.geronimo.kernel.basic.RawOperationInvoker.invoke(RawOperationInvoker.java:35)
>  >         at
>  >org.apache.geronimo.kernel.basic.ProxyMethodInterceptor.intercept(ProxyMethodInterceptor.java:96)
>  >         at
>  >org.apache.geronimo.deployment.ConfigurationBuilder$$EnhancerByCGLIB$$4c1d63a.getDeploymentPlan(<generated>)
>  >         at
>  >org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:232)
>  >         at
>  >org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:124)
>  >         at
>  >org.apache.geronimo.deployment.Deployer$$FastClassByCGLIB$$734a235d.invoke(<generated>)
>  >         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:53)
>  >         at
>  >org.apache.geronimo.gbean.runtime.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
>  >         at
>  >org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:122)
>  >         at
>  >org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:852)
>  >         at
>  >org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:239)
>  >         at
>  >org.apache.geronimo.deployment.plugin.local.AbstractDeployCommand.doDeploy(AbstractDeployCommand.java:106)
>  >         at
>  >org.apache.geronimo.deployment.plugin.local.DistributeCommand.run(DistributeCommand.java:60)
>  >         at java.lang.Thread.run(Thread.java:534)
>  >
>  >What am I missing?
>  >My EAR contains the following:
>  >APP-INF/lib:
>  >         a bunch of shared jar files under APP-INF/lib
>  >META-INF:
>  >         application.xml
>  >         MANIFEST.MF
>  >and a bunch of EJB jars in the root of the EAR
>  >
>  >Each EJB jar contains:
>  >classes under the root
>  >META-INF:
>  >         MANIFEST.MF (they have references to jars in the EAR where
>  >dependencies exist
>  >
>  >My application.xml looks like:
>  ><?xml version="1.0" encoding="UTF-8"?>
>  ><!DOCTYPE application PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE
>  >Application 1.3//EN" "http://java.sun.com/dtd/application_1_3.dtd">
>  ><application>
>  >   <display-name>MyAppName</display-name>
>  >   <module>
>  >     <ejb>MyEJB.jar</ejb>
>  >   </module>
>  >   <!-- and a bunch more ejbs -->
>  ></application>
>  >
>  >Are there any other configuration files that I need? I got the impression
>  >that the rest were all optional, but I'm guessing that I'm wrong.
>  >
>  >--
>  >Jimmy Wan
>  >21st Century Technologies, Inc.
>  >4515 Seton Center Parkway Suite 320
>  >Austin, TX 78759
>  >
>  >URL: http://www.21technologies.com
>  >The information in this email and in any attachments is confidential and
>  >may be privileged. If you are not the intended recipient, please destroy
>  >this message, delete any copies held on your systems and notify the sender
>  >immediately. You should not retain, copy or use this email for any
>  >purpose, nor disclose all or any part of its content to any other person.

Reply via email to