You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@geronimo.apache.org by foxxalla <cn...@yahoo.com> on 2008/05/09 06:12:02 UTC

Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

I have the following deployment plan when I deploy the ear i get the
exception below. 
The connectors work stand alone but I need them to get deployed together
from the 
same application any ideas ?


<?xml version="1.0" encoding="UTF-8"?>
<application xmlns="http://geronimo.apache.org/xml/ns/j2ee/application-1.2">
  <environment xmlns="http://geronimo.apache.org/xml/ns/deployment-1.2">
    <moduleId>
      <groupId>org.apache.geronimo.samples</groupId>
      <artifactId>MyPhonebook</artifactId>
      <version>1.0</version>
      <type>ear</type>
    </moduleId>
  </environment>
   <module>
	<connector>tranql-connector-ra-1.3.rar</connector>
	<alt-dd>PhoneBookPool.xml</alt-dd>
</module> 
<module>
	<connector>geronimo-activemq-ra-2.0-SNAPSHOT.rar</connector>
	<alt-dd>JMSQueue.xml</alt-dd>
</module>
</application>



Geronimo ear plan contains modules that aren't in the ear: true
org.apache.geronimo.common.DeploymentException: Geronimo ear plan contains
modules that aren't in the ear: true
	at
org.apache.geronimo.j2ee.deployment.EARConfigBuilder.addModules(EARConfigBuilder.java:893)
	at
org.apache.geronimo.j2ee.deployment.EARConfigBuilder.getEarPlan(EARConfigBuilder.java:402)
	at
org.apache.geronimo.j2ee.deployment.EARConfigBuilder.getDeploymentPlan(EARConfigBuilder.java:295)
	at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:226)
	at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:133)
	at sun.reflect.GeneratedMethodAccessor315.invoke(Unknown Source)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at
org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java:34)
	at
org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:124)
	at
org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:867)
	at
org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:239)
	at
org.apache.geronimo.deployment.plugin.local.AbstractDeployCommand.doDeploy(AbstractDeployCommand.java:116)
	at
org.apache.geronimo.deployment.plugin.local.DistributeCommand.run(DistributeCommand.java:61)
	at java.lang.Thread.run(Thread.java:619)


-- 
View this message in context: http://www.nabble.com/Problem-with-Deployment-plan-%28Geronimo-ear-plan-contains-modules-that-aren%27t-in-the-ear%3A-true%29-tp17141114s134p17141114.html
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

Posted by Viet Nguyen <vh...@gmail.com>.
If you put the mysql connector jar in the top level of the EAR, you
will not need to set a dependency for it. You can just adjust the pom
to include the connector jar. This way, you just need to deploy the
EAR without previously having the mysql connector installed in
Geronimo.

Hope this helps,
Viet

Re: Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

Posted by Spastik <cn...@yahoo.com>.
Thanks 
I managed to fix it

Now I was testing deployment and I want to know if i can put the
mysql-connector-java-3.0.17.jar embedded in the ear file and  fix the
deployment plan in such a way that makes the application deployable without
the need for further setup from the console i.e downloading the driver 

Thanks in Advance

F.M
-- 
View this message in context: http://www.nabble.com/Problem-with-Deployment-plan-%28Geronimo-ear-plan-contains-modules-that-aren%27t-in-the-ear%3A-true%29-tp17141114s134p17158966.html
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

Posted by Viet Nguyen <vh...@gmail.com>.
You don't need to set a dependency on the jms-resource*.rar because
you have it defined in your EAR. It is automatically loaded into the
EAR classloader. You only need to set dependencies on something that
is not in your application (e.g. you will need to set a dependency on
the mysql-connector*.jar in your openejb-jar.xml).

--Viet

Re: Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

Posted by Spastik <cn...@yahoo.com>.

ok I had a missing dependency but now iI have a different exception at
deployment. I uploaded the whole project so that one can help me spot the
problem

Deployment failed:
Unable to create configuration for deployment 
http://www.nabble.com/file/p17146209/myphonebook.rar myphonebook.rar 


Unable to create configuration for deployment
org.apache.geronimo.common.DeploymentException: Unable to create
configuration for deployment
	at
org.apache.geronimo.deployment.DeploymentContext.createTempConfiguration(DeploymentContext.java:120)
	at
org.apache.geronimo.deployment.DeploymentContext.<init>(DeploymentContext.java:100)
	at
org.apache.geronimo.deployment.DeploymentContext.<init>(DeploymentContext.java:80)
	at
org.apache.geronimo.j2ee.deployment.EARContext.<init>(EARContext.java:68)
	at
org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:530)
	at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:254)
	at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:133)
	at sun.reflect.GeneratedMethodAccessor315.invoke(Unknown Source)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at
org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java:34)
	at
org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:124)
	at
org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:867)
	at
org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:239)
	at
org.apache.geronimo.deployment.plugin.local.AbstractDeployCommand.doDeploy(AbstractDeployCommand.java:116)
	at
org.apache.geronimo.deployment.plugin.local.DistributeCommand.run(DistributeCommand.java:61)
	at java.lang.Thread.run(Thread.java:619)
Caused by: org.apache.geronimo.kernel.config.LifecycleException: load of
org.apache.geronimo.samples/MyPhonebook/1.0/ear failed
	at
org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:327)
	at
org.apache.geronimo.deployment.DeploymentConfigurationManager.loadConfiguration(DeploymentConfigurationManager.java:115)
	at
org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:286)
	at
org.apache.geronimo.deployment.DeploymentConfigurationManager.loadConfiguration(DeploymentConfigurationManager.java:111)
	at
org.apache.geronimo.deployment.DeploymentContext.createTempConfiguration(DeploymentContext.java:117)
	... 16 more
Caused by: org.apache.geronimo.kernel.config.InvalidConfigException: Error
starting configuration gbean org.apache.geronimo.samples/MyPhonebook/1.0/ear
	at
org.apache.geronimo.kernel.config.SimpleConfigurationManager.load(SimpleConfigurationManager.java:352)
	at
org.apache.geronimo.deployment.DeploymentConfigurationManager.load(DeploymentConfigurationManager.java:119)
	at
org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:312)
	... 20 more
Caused by: org.apache.geronimo.kernel.repository.MissingDependencyException:
Missing dependency: org.apache.geronimo.samples/jms-resources/1.2/rar
	at
org.apache.geronimo.kernel.config.ConfigurationResolver.resolve(ConfigurationResolver.java:113)
	at
org.apache.geronimo.kernel.config.Configuration.buildClassPath(Configuration.java:405)
	at
org.apache.geronimo.kernel.config.Configuration.createConfigurationClasssLoader(Configuration.java:322)
	at
org.apache.geronimo.kernel.config.Configuration.<init>(Configuration.java:267)
	at
org.apache.geronimo.kernel.config.SimpleConfigurationManager.load(SimpleConfigurationManager.java:348)
	... 22 more

-- 
View this message in context: http://www.nabble.com/Problem-with-Deployment-plan-%28Geronimo-ear-plan-contains-modules-that-aren%27t-in-the-ear%3A-true%29-tp17141114s134p17146209.html
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

Posted by Viet Nguyen <vh...@gmail.com>.
I'm not sure what your pom looks like, but I suspect you are missing
this key piece in the pom.xml of the EAR.

             <plugin>
                 <artifactId>maven-ear-plugin</artifactId>
                 <configuration>
                     <displayName>Geronimo Sample EAR for
jms-mdb-sample</displayName>
                     <description>Geronimo Sample EAR for
jms-mdb-sample</description>
                     <version>5</version>
                     <modules>
                       <rarModule>
                             <groupId>org.apache.geronimo.modules</groupId>
                             <artifactId>geronimo-activemq-ra</artifactId>

<bundleFileName>geronimo-activemq-ra-${geronimoVersion}.rar</bundleFileName>
                         </rarModule>

                       <ejbModule>
                             <groupId>org.apache.geronimo.samples</groupId>
                             <artifactId>jms-mdb-sample-ejb</artifactId>

<bundleFileName>jms-mdb-sample-ejb-${version}.jar</bundleFileName>
                         </ejbModule>

                         <webModule>
                             <groupId>org.apache.geronimo.samples</groupId>
                             <artifactId>jms-mdb-sample-war</artifactId>
                             <contextRoot>/order</contextRoot>

<bundleFileName>jms-mdb-sample-war-${version}.war</bundleFileName>
                         </webModule>
                     </modules>
                 </configuration>
             </plugin>

To really test it, you'll probably want to pull down the sample
application (trunk) and look at the poms.

Hope this helps,
Viet

On Fri, May 9, 2008 at 12:47 AM, Spastik <cn...@yahoo.com> wrote:
>
> I tried to merge
>
> http://cwiki.apache.org/GMOxDOC20/very-simple-entity-ejb-example.html
>
> and
>
> http://cwiki.apache.org/GMOxDOC20/jms-and-mdb-sample-application.html
>
> because I want to deploy both a  database pool and JMS Resource.
> Maven creats the Ear just fine but when i unzipped it to check
> geronimo-activemq is missing. Is is because I have more than one
> module in the deployment plan ?
>
>
>
>
> vhnguy2 wrote:
>>
>> Hello,
>>
>> Does your EAR contain the two modules that you specified in the DD (ie
>> tranql-connector and geronimo-activemq)? You need to have those
>> RAR/JARs and the xml files residing in the top-level directory of your
>> EAR.
>>
>> There are sample applications that shows how to do this (e.g.
>> http://cwiki.apache.org/GMOxDOC21/jms-and-mdb-sample-application.html)
>>
>> Hope this helps,
>> Viet
>>
>>
>
> --
> View this message in context: http://www.nabble.com/Problem-with-Deployment-plan-%28Geronimo-ear-plan-contains-modules-that-aren%27t-in-the-ear%3A-true%29-tp17141114s134p17141333.html
> Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.
>
>

Re: Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

Posted by Spastik <cn...@yahoo.com>.
I tried to merge 

http://cwiki.apache.org/GMOxDOC20/very-simple-entity-ejb-example.html

and 

http://cwiki.apache.org/GMOxDOC20/jms-and-mdb-sample-application.html

because I want to deploy both a  database pool and JMS Resource.
Maven creats the Ear just fine but when i unzipped it to check
geronimo-activemq is missing. Is is because I have more than one
module in the deployment plan ?




vhnguy2 wrote:
> 
> Hello,
> 
> Does your EAR contain the two modules that you specified in the DD (ie
> tranql-connector and geronimo-activemq)? You need to have those
> RAR/JARs and the xml files residing in the top-level directory of your
> EAR.
> 
> There are sample applications that shows how to do this (e.g.
> http://cwiki.apache.org/GMOxDOC21/jms-and-mdb-sample-application.html)
> 
> Hope this helps,
> Viet
> 
> 

-- 
View this message in context: http://www.nabble.com/Problem-with-Deployment-plan-%28Geronimo-ear-plan-contains-modules-that-aren%27t-in-the-ear%3A-true%29-tp17141114s134p17141333.html
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: Problem with Deployment plan (Geronimo ear plan contains modules that aren't in the ear: true)

Posted by Viet Nguyen <vh...@gmail.com>.
Hello,

Does your EAR contain the two modules that you specified in the DD (ie
tranql-connector and geronimo-activemq)? You need to have those
RAR/JARs and the xml files residing in the top-level directory of your
EAR.

There are sample applications that shows how to do this (e.g.
http://cwiki.apache.org/GMOxDOC21/jms-and-mdb-sample-application.html)

Hope this helps,
Viet