You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@geronimo.apache.org by BLB 4SOFF <bl...@gmail.com> on 2014/03/03 14:36:09 UTC

MissingDependencyException with geronimo-tomcat6-javaee5-2.1.8

Hi,

I need help for using geronimo 2.1.8 (I've tested also with 2.2.1 with
the same result).
My goal is to give some EARs and RARs as examples in a Geronimo environment.

So I put a RAR archive and an EAR one that depends on that RAR in
Geronimo deploy directory.
The deployment is done that way because several EARs can use the same rar.

It seems that the ear is deployed before the rar so the dependency is
not resolved by Geronimo.


I encounter the problem on a linux system (and not with windows 7 for
the moment : perhaps because my windows VM is slower).


When Geronimo starts, I get the following exception

2014-02-20 14:34:43,349 INFO [DirectoryHotDeployer] Deploying
vsims-ear-4.1.0-SNAPSHOT.ear
2014-02-20 14:34:43,552 ERROR [DirectoryHotDeployer] Unable to deploy:
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:151)
  at org.apache.geronimo.deployment.DeploymentContext.<init>(DeploymentContext.java:131)
  at org.apache.geronimo.deployment.DeploymentContext.<init>(DeploymentContext.java:111)
  at org.apache.geronimo.j2ee.deployment.EARContext.<init>(EARContext.java:64)
  at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:521)
  at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:257)
  at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:136)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  at java.lang.reflect.Method.invoke(Method.java:606)
  at org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java:34)
  at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:130)
  at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:851)
  at org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:237)
  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:744)
Caused by: org.apache.geronimo.kernel.config.LifecycleException: load
of mycompany.demos/vsims-ear/4.1.0-SNAPSHOT/ear failed
  at org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:316)
  at org.apache.geronimo.deployment.DeploymentConfigurationManager.loadConfiguration(DeploymentConfigurationManager.java:115)
  at org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:277)
  at org.apache.geronimo.deployment.DeploymentConfigurationManager.loadConfiguration(DeploymentConfigurationManager.java:111)
  at org.apache.geronimo.deployment.DeploymentContext.createTempConfiguration(DeploymentContext.java:148)
... 17 more
Caused by: org.apache.geronimo.kernel.config.InvalidConfigException:
Error starting configuration gbean
mycompany.demos/vsims-ear/4.1.0-SNAPSHOT/ear
  at org.apache.geronimo.kernel.config.SimpleConfigurationManager.load(SimpleConfigurationManager.java:341)
  at org.apache.geronimo.deployment.DeploymentConfigurationManager.load(DeploymentConfigurationManager.java:119)
  at org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:302)
... 21 more
Caused by: org.apache.geronimo.kernel.repository.MissingDependencyException:
Missing dependency: mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar
  at org.apache.geronimo.kernel.config.ConfigurationResolver.resolve(ConfigurationResolver.java:113)
  at org.apache.geronimo.kernel.config.Configuration.buildClassPath(Configuration.java:415)
  at org.apache.geronimo.kernel.config.Configuration.createConfigurationClasssLoader(Configuration.java:339)
  at org.apache.geronimo.kernel.config.Configuration.<init>(Configuration.java:281)
  at org.apache.geronimo.kernel.config.SimpleConfigurationManager.load(SimpleConfigurationManager.java:337)
... 23 more


Later on, we can see in Geroniomo log

2014-02-20 14:34:51,613 INFO [DirectoryHotDeployer] Deploying
imsrar-3.1.0-SNAPSHOT.rar
2014-02-20 14:34:51,620 INFO [config] Extracting jar:
/tmp/geronimo-deployer800879740792626301.tmpdir/imsrar-3.1.0-SNAPSHOT.rar
2014-02-20 14:34:51,635 INFO [config] Extracted path:
/tmp/geronimo-deployer800879740792626301.tmpdir/imsrar-3.1.0-SNAPSHOT
2014-02-20 14:34:51,969 INFO [KernelContextGBean] bound gbean
mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar?J2EEApplication=null,JCAConnectionFactory=imsConnectionFactory,JCAResource=mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar,ResourceAdapter=mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar,ResourceAdapterModule=mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar,j2eeType=JCAManagedConnectionFactory,name=imsConnectionFactory
at name mycompany.ims/ImsConnectAdapter/JCAManagedConnectionFactory/imsConnectionFactory
2014-02-20 14:34:52,017 INFO [DirectoryHotDeployer] Deployed
mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar


The vsims-ear-4.1.0-SNAPSHOT.ear is removed.
If I stop Geronimo, put again that EAR in the deploy dir and restart
Geronimo, the exception disappears.

Is there a way to avoid that exception when Geronimo starts the first time ?

Or should I re-consider the way applications are deployed (without
using the deploy dir) ?

Thanks for your help.

Regards
Fabrice

Re: MissingDependencyException with geronimo-tomcat6-javaee5-2.1.8

Posted by BLB 4SOFF <bl...@gmail.com>.
Hi David,

Thanks for your answer.

Fabrice

Re: MissingDependencyException with geronimo-tomcat6-javaee5-2.1.8

Posted by David Jencks <da...@yahoo.com>.
As far as I know there is no way to work around this problem when deploying using the deploy directory.

I think your options are to write a script to deploy the applications in the order you need or to pre-deploy them as car files and perhaps build a custom server assembly including them.

david jencks

On Mar 3, 2014, at 5:36 AM, BLB 4SOFF <bl...@gmail.com> wrote:

> Hi,
> 
> I need help for using geronimo 2.1.8 (I've tested also with 2.2.1 with
> the same result).
> My goal is to give some EARs and RARs as examples in a Geronimo environment.
> 
> So I put a RAR archive and an EAR one that depends on that RAR in
> Geronimo deploy directory.
> The deployment is done that way because several EARs can use the same rar.
> 
> It seems that the ear is deployed before the rar so the dependency is
> not resolved by Geronimo.
> 
> 
> I encounter the problem on a linux system (and not with windows 7 for
> the moment : perhaps because my windows VM is slower).
> 
> 
> When Geronimo starts, I get the following exception
> 
> 2014-02-20 14:34:43,349 INFO [DirectoryHotDeployer] Deploying
> vsims-ear-4.1.0-SNAPSHOT.ear
> 2014-02-20 14:34:43,552 ERROR [DirectoryHotDeployer] Unable to deploy:
> 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:151)
> at org.apache.geronimo.deployment.DeploymentContext.<init>(DeploymentContext.java:131)
> at org.apache.geronimo.deployment.DeploymentContext.<init>(DeploymentContext.java:111)
> at org.apache.geronimo.j2ee.deployment.EARContext.<init>(EARContext.java:64)
> at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:521)
> at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:257)
> at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:136)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java:34)
> at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:130)
> at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:851)
> at org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:237)
> 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:744)
> Caused by: org.apache.geronimo.kernel.config.LifecycleException: load
> of mycompany.demos/vsims-ear/4.1.0-SNAPSHOT/ear failed
> at org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:316)
> at org.apache.geronimo.deployment.DeploymentConfigurationManager.loadConfiguration(DeploymentConfigurationManager.java:115)
> at org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:277)
> at org.apache.geronimo.deployment.DeploymentConfigurationManager.loadConfiguration(DeploymentConfigurationManager.java:111)
> at org.apache.geronimo.deployment.DeploymentContext.createTempConfiguration(DeploymentContext.java:148)
> ... 17 more
> Caused by: org.apache.geronimo.kernel.config.InvalidConfigException:
> Error starting configuration gbean
> mycompany.demos/vsims-ear/4.1.0-SNAPSHOT/ear
> at org.apache.geronimo.kernel.config.SimpleConfigurationManager.load(SimpleConfigurationManager.java:341)
> at org.apache.geronimo.deployment.DeploymentConfigurationManager.load(DeploymentConfigurationManager.java:119)
> at org.apache.geronimo.kernel.config.SimpleConfigurationManager.loadConfiguration(SimpleConfigurationManager.java:302)
> ... 21 more
> Caused by: org.apache.geronimo.kernel.repository.MissingDependencyException:
> Missing dependency: mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar
> at org.apache.geronimo.kernel.config.ConfigurationResolver.resolve(ConfigurationResolver.java:113)
> at org.apache.geronimo.kernel.config.Configuration.buildClassPath(Configuration.java:415)
> at org.apache.geronimo.kernel.config.Configuration.createConfigurationClasssLoader(Configuration.java:339)
> at org.apache.geronimo.kernel.config.Configuration.<init>(Configuration.java:281)
> at org.apache.geronimo.kernel.config.SimpleConfigurationManager.load(SimpleConfigurationManager.java:337)
> ... 23 more
> 
> 
> Later on, we can see in Geroniomo log
> 
> 2014-02-20 14:34:51,613 INFO [DirectoryHotDeployer] Deploying
> imsrar-3.1.0-SNAPSHOT.rar
> 2014-02-20 14:34:51,620 INFO [config] Extracting jar:
> /tmp/geronimo-deployer800879740792626301.tmpdir/imsrar-3.1.0-SNAPSHOT.rar
> 2014-02-20 14:34:51,635 INFO [config] Extracted path:
> /tmp/geronimo-deployer800879740792626301.tmpdir/imsrar-3.1.0-SNAPSHOT
> 2014-02-20 14:34:51,969 INFO [KernelContextGBean] bound gbean
> mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar?J2EEApplication=null,JCAConnectionFactory=imsConnectionFactory,JCAResource=mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar,ResourceAdapter=mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar,ResourceAdapterModule=mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar,j2eeType=JCAManagedConnectionFactory,name=imsConnectionFactory
> at name mycompany.ims/ImsConnectAdapter/JCAManagedConnectionFactory/imsConnectionFactory
> 2014-02-20 14:34:52,017 INFO [DirectoryHotDeployer] Deployed
> mycompany.ims/ImsConnectAdapter/3.1.0-SNAPSHOT/rar
> 
> 
> The vsims-ear-4.1.0-SNAPSHOT.ear is removed.
> If I stop Geronimo, put again that EAR in the deploy dir and restart
> Geronimo, the exception disappears.
> 
> Is there a way to avoid that exception when Geronimo starts the first time ?
> 
> Or should I re-consider the way applications are deployed (without
> using the deploy dir) ?
> 
> Thanks for your help.
> 
> Regards
> Fabrice