You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by almos <al...@ukr.net> on 2012/06/04 17:38:55 UTC

DuplicateDeploymentIdException when deploying ear with application.xml

Hello,

I am facing strange following problem when using application.xml in my EAR
file.

1. I am using maven to build EAR which contains JAR with EJB components and
one web application WAR
2. Maven automatically creates application.xml in the META-INF of my EAR
3. When deploying EAR on TomEE+ 1.0 deploy succeeds - web application and
EJB's gets deployed and works fine but I get annoying exception in the log
files:

SEVERE: Unable to deploy collapsed ear in war /BMM-0.0.1-SNAPSHOT:
Exception: Application cannot be deployed as it contains deployment-ids
which are in use: app:
/Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
    Bean1
    Bean2
    Bean3
org.apache.openejb.DuplicateDeploymentIdException: Application cannot be
deployed as it contains deployment-ids which are in use: app:
/Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
    Bean1
    Bean2
    Bean3
	at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:540)
	at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:506)
	at
org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:634)
	at
org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:588)
	at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:117)
	at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
	at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5161)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
	at
org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
	at
org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:680)
04.06.2012 18:18:25 org.apache.catalina.core.ContainerBase addChildInternal
SEVERE: ContainerBase.addChild: start: 
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/BMM-0.0.1-SNAPSHOT]]
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
	at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
	at
org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
	at
org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:680)
Caused by: org.apache.tomee.catalina.TomEERuntimeException:
org.apache.openejb.DuplicateDeploymentIdException: Application cannot be
deployed as it contains deployment-ids which are in use: app:
/Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
    Bean1
    Bean2
    Bean3
	at
org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:641)
	at
org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:588)
	at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:117)
	at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
	at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5161)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	... 11 more
Caused by: org.apache.openejb.DuplicateDeploymentIdException: Application
cannot be deployed as it contains deployment-ids which are in use: app:
/Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
    Bean1
    Bean2
    Bean3
	at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:540)
	at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:506)
	at
org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:634)
	... 17 more
04.06.2012 18:18:25 org.apache.catalina.startup.HostConfig deployDirectory
SEVERE: Error deploying web application directory
/Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
java.lang.IllegalStateException: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/BMM-0.0.1-SNAPSHOT]]
	at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:898)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
	at
org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
	at
org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:680)





Generated application.xml looks following:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE application PUBLIC
	&quot;-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN&quot;
	&quot;http://java.sun.com/dtd/application_1_3.dtd&quot;>
<application>
  <display-name>BMM EAR module</display-name>
  <module>
    <ejb>backend-0.0.1-SNAPSHOT.jar</ejb>
  </module>
  <module>
    <web>
      <web-uri>frontend-0.0.1-SNAPSHOT.war</web-uri>
      <context-root>/frontend</context-root>
    </web>
  </module>
</application>

So eventually after deploy succeeds TomEE unpacks EAR and it looks like that
after unpack it tries to deploy it once more, however I am not sure.

Does anybody seen this? How can I fix this or just disable EAR unpack in the
web apps?

Thanks,
Alex

--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
great!

thanks to give your feedback btw.

- Romain


2012/8/11 almos <al...@ukr.net>

> Thanks for pointing to that jira entry. Adding ?daemon=true to the uri
> fixed
> the problem.
> Now TomEE stops fine without need to stop ActiveMQ first. Also during
> deploy/redeploy process there are no issues with jsp and servlets which was
> the case in 1.0.0 version.
>
> Thanks a lot for the support!
>
> Regards,
> Alex
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656799.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Thanks for pointing to that jira entry. Adding ?daemon=true to the uri fixed
the problem.
Now TomEE stops fine without need to stop ActiveMQ first. Also during
deploy/redeploy process there are no issues with jsp and servlets which was
the case in 1.0.0 version.

Thanks a lot for the support!

Regards,
Alex



--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656799.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
weird, daemon=true seems enough:
https://issues.apache.org/jira/browse/AMQ-1447

but in your stack the transport threads are not daemon

- Romain


2012/8/2 almos <al...@ukr.net>

> I sent it my previous post (Jul 26, 2012; 12:02pm) with a link - looks like
> system rejected it.
> Dump could be found here - http:// sharetext.org /EPGC (without spaces)
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656638.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
I sent it my previous post (Jul 26, 2012; 12:02pm) with a link - looks like
system rejected it.
Dump could be found here - http:// sharetext.org /EPGC (without spaces)



--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656638.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
A threadump if i'm not misreading
Le 1 août 2012 19:26, "almos" <al...@ukr.net> a écrit :

> Is there any news on this? Should I have to sent more related info?
>
> Thanks.
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656621.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Is there any news on this? Should I have to sent more related info?

Thanks.



--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656621.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
would be nice to get a threadump (jstack) at this moment

is it possible?

- Romain


2012/7/25 almos <al...@ukr.net>

> 1. Not sure I understood what do you mean. But we can't run ActiveMQ under
> TomEE, we are running separate ActiveMQ cluster
> 2. Upgrade of ActiveMQ to 5.6.0 haven't helped. Same hang occurs on
> application undeploy/TomEE shutdown
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656532.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
1. Not sure I understood what do you mean. But we can't run ActiveMQ under
TomEE, we are running separate ActiveMQ cluster
2. Upgrade of ActiveMQ to 5.6.0 haven't helped. Same hang occurs on
application undeploy/TomEE shutdown



--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656532.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hmm, 2 notes about it 1) i think amq uri can be customized to be daemon, 2)
using amq 5.6 can fix it since 5.5 got some bug
Le 22 juil. 2012 14:35, "almos" <al...@ukr.net> a écrit :

> I was keep trying to figure out why TomEE hangs on undeploy/shutdown for me
> (and that doesnt happen for you) and looks like I have found the reason.
>
> When I have active MDBs listening on queues/topics TomEE doesn't stop until
> ActiveMQ is shut down.
>
> Here is a test application where there are either ejb and mdb -
> http://www.4shared.com/zip/Sj1fMmQX/testear2.html.
>
> ActiveMQ version I use is 5.5.1. TomEE - 1.0.
> We were able to reproduce behavior on every platform (Windows/MacOS/Linux).
>
> Steps for reproduction:
>
> 1. Start ActiveMQ
> (/Work/java/apache-activemq-5.5.1/bin/activemq start)
> 2. Start TomEE
> (/Work/java/tomee-remote/bin/startup.sh)
> 3. Deploy application with MDB
> (/Work/java/tomee-remote/bin/tomee.sh deploy
> /tmp/eartest-0.0.1-SNAPSHOT.ear)
> 4. Ensure application has been loaded
> 5. Stop TomEE or try undeploying application
> 6. On shutdown TomEE will hang with following in catalina.out
>
> 22.07.2012 13:31:08 org.apache.coyote.AbstractProtocol stop
> INFO: Stopping ProtocolHandler ["ajp-bio-8009"]
> 22.07.2012 13:31:08 org.apache.openejb.server.SimpleServiceManager stop
> INFO: Stopping server services
> 22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler
> destroyApplication
> INFO: Undeploying app: openejb
> 22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler destroy
> INFO: Closing DataSource: BerimbiDataSourceUnmanaged
> 22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler destroy
> INFO: Closing DataSource: BerimbiDataSourceManaged
> 22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler destroy
> INFO: Stopping ResourceAdapter: ActiveMQProvider
> 22.07.2012 13:31:08
> org.apache.openejb.resource.activemq.ActiveMQResourceAdapter stop
> INFO: Stopping ActiveMQ
> 22.07.2012 13:31:08
> org.apache.openejb.resource.activemq.ActiveMQResourceAdapter stopImpl
> INFO: Stopped ActiveMQ broker
> 22.07.2012 13:31:08 org.apache.coyote.AbstractProtocol destroy
> INFO: Destroying ProtocolHandler ["http-bio-8080"]
> 22.07.2012 13:31:08 org.apache.coyote.AbstractProtocol destroy
> INFO: Destroying ProtocolHandler ["ajp-bio-8009"]
>
> 7. Stop ActiveMQ
> (/Work/java/apache-activemq-5.5.1/bin/activemq stop)
> 8. Check TomEE, it should stop right after ActiveMQ killed
>
> When I shut down ActiveMQ before TomEE, TomEE releases fine without any
> hangs.
>
> So somehow TomEE waiting somewhat from ActiveMQ. The same happens when
> TomEE
> and ActiveMQ running on different machines.
>
> My tomee.xml contains following in regards of ActiveMQ configuration:
>
>
> <Resource id="ActiveMQProvider" type="ActiveMQResourceAdapter">
>         BrokerXmlConfig =
>         ServerUrl = tcp://localhost:61616
> </Resource>
>
> <Resource id="ActiveMQConnectionFactory"
> type="javax.jms.ConnectionFactory">
>         ResourceAdapter = ActiveMQProvider
> </Resource>
>
> <Container id="ActiveMQMDBContainer" ctype="MESSAGE">
>         ResourceAdapter = ActiveMQProvider
> </Container>
>
> <Resource id="ismTopic" type="javax.jms.Topic" />
>
> Is there any issue with my config/MDB configuration?
>
> Regards,
> Alex
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656478.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
I was keep trying to figure out why TomEE hangs on undeploy/shutdown for me
(and that doesnt happen for you) and looks like I have found the reason.

When I have active MDBs listening on queues/topics TomEE doesn't stop until
ActiveMQ is shut down.

Here is a test application where there are either ejb and mdb -
http://www.4shared.com/zip/Sj1fMmQX/testear2.html.

ActiveMQ version I use is 5.5.1. TomEE - 1.0.
We were able to reproduce behavior on every platform (Windows/MacOS/Linux).

Steps for reproduction:

1. Start ActiveMQ
(/Work/java/apache-activemq-5.5.1/bin/activemq start)
2. Start TomEE
(/Work/java/tomee-remote/bin/startup.sh)
3. Deploy application with MDB
(/Work/java/tomee-remote/bin/tomee.sh deploy
/tmp/eartest-0.0.1-SNAPSHOT.ear)
4. Ensure application has been loaded
5. Stop TomEE or try undeploying application
6. On shutdown TomEE will hang with following in catalina.out

22.07.2012 13:31:08 org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["ajp-bio-8009"]
22.07.2012 13:31:08 org.apache.openejb.server.SimpleServiceManager stop
INFO: Stopping server services
22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler
destroyApplication
INFO: Undeploying app: openejb
22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler destroy
INFO: Closing DataSource: BerimbiDataSourceUnmanaged
22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler destroy
INFO: Closing DataSource: BerimbiDataSourceManaged
22.07.2012 13:31:08 org.apache.openejb.assembler.classic.Assembler destroy
INFO: Stopping ResourceAdapter: ActiveMQProvider
22.07.2012 13:31:08
org.apache.openejb.resource.activemq.ActiveMQResourceAdapter stop
INFO: Stopping ActiveMQ
22.07.2012 13:31:08
org.apache.openejb.resource.activemq.ActiveMQResourceAdapter stopImpl
INFO: Stopped ActiveMQ broker
22.07.2012 13:31:08 org.apache.coyote.AbstractProtocol destroy
INFO: Destroying ProtocolHandler ["http-bio-8080"]
22.07.2012 13:31:08 org.apache.coyote.AbstractProtocol destroy
INFO: Destroying ProtocolHandler ["ajp-bio-8009"]

7. Stop ActiveMQ
(/Work/java/apache-activemq-5.5.1/bin/activemq stop)
8. Check TomEE, it should stop right after ActiveMQ killed

When I shut down ActiveMQ before TomEE, TomEE releases fine without any
hangs.

So somehow TomEE waiting somewhat from ActiveMQ. The same happens when TomEE
and ActiveMQ running on different machines.

My tomee.xml contains following in regards of ActiveMQ configuration:


<Resource id="ActiveMQProvider" type="ActiveMQResourceAdapter">
	BrokerXmlConfig = 
	ServerUrl = tcp://localhost:61616
</Resource>

<Resource id="ActiveMQConnectionFactory" type="javax.jms.ConnectionFactory">
	ResourceAdapter = ActiveMQProvider
</Resource>

<Container id="ActiveMQMDBContainer" ctype="MESSAGE">
	ResourceAdapter = ActiveMQProvider
</Container>

<Resource id="ismTopic" type="javax.jms.Topic" />

Is there any issue with my config/MDB configuration?

Regards,
Alex



--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4656478.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
weird since it worked for me

- Romain


2012/6/28 almos <al...@ukr.net>

> I did use folder name when wrote you previous message instead of ear name
> but
> it didn't work as described.
>
> Using relative path being outside of the $TOMEE_HOME doesn't work as well -
> it can't find deployed application:
>
> $TOMEE_HOME/bin/tomee.sh undeploy apps/BMM-0.0.2-SNAPSHOT
>
> undeploying apps/BMM-0.0.2-SNAPSHOT
> 28.06.2012 16:52:08 org.apache.openejb.client.EventLogger log
> INFO:
> RemoteInitialContextCreated{providerUri=http://localhost:8080/tomee/ejb}
> Module with moduleId "apps/BMM-0.0.2-SNAPSHOT" does not exist.
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655869.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
I did use folder name when wrote you previous message instead of ear name but
it didn't work as described. 

Using relative path being outside of the $TOMEE_HOME doesn't work as well -
it can't find deployed application:

$TOMEE_HOME/bin/tomee.sh undeploy apps/BMM-0.0.2-SNAPSHOT

undeploying apps/BMM-0.0.2-SNAPSHOT
28.06.2012 16:52:08 org.apache.openejb.client.EventLogger log
INFO:
RemoteInitialContextCreated{providerUri=http://localhost:8080/tomee/ejb}
Module with moduleId "apps/BMM-0.0.2-SNAPSHOT" does not exist.



--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655869.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

RE: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Robin <ro...@gmail.com>.
Please remove me from this list

-----Original Message-----
From: Romain Manni-Bucau [mailto:rmannibucau@gmail.com] 
Sent: Tuesday, June 26, 2012 8:18 AM
To: users@openejb.apache.org
Subject: Re: DuplicateDeploymentIdException when deploying ear with
application.xml

guess i found the issue

currently the deploy used copy the deployed app in apps/ folder (in tomee)
so when undeploying it you need to give the apps/<app folder> path.

here the command i used:

./bin/tomee.sh deploy /tmp/testear/ear/target/eartest-0.0.1-SNAPSHOT.ear
./bin/tomee.sh undeploy /foo/apache-tomee/apps/eartest-0.0.1-SNAPSHOT


- Romain


2012/6/26 almos <al...@ukr.net>

> Sorry for not responding for quite long time on this.
>
> Yes, you are right, you need to use tomee.sh for that to reproduce the 
> issue.
>
> Exact steps are:
>
> 1. Deploy application
>
> MBP-Almos:testear2 tomee.sh deploy /tmp/eartest-0.0.1-SNAPSHOT.ear
>
> 2. Check jsp page/servlet
>
> MBP-Almos:testear2 wget http://localhost:8080/frontend/test.jsp -O -
>
> <!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 
> Transitional//EN&quot; 
> &quot;http://www.w3.org/TR/html4/loose.dtd&quot;>
> <html>
> <head>
> <meta http-equiv="Content-Type" content="text/html; 
> charset=ISO-8859-1"> <title>Client</title> <body> test page
>
> </body>
>
> 3. Undeploy application
>
> tomee.sh undeploy
> /Work/java/apache-tomee-plus-1.0.0/apps/eartest-0.0.1-SNAPSHOT/
>
> 4. Check servlet/jsp page availability
>
> wget http://localhost:8080/frontend/test.jsp -O -
>
> <!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 
> Transitional//EN&quot; 
> &quot;http://www.w3.org/TR/html4/loose.dtd&quot;>
> <html>
> <head>
> <meta http-equiv="Content-Type" content="text/html; 
> charset=ISO-8859-1"> <title>Client</title> <body> test page
>
> </body>
>
> It's still available.
>
> Tries to access EJB results in the error messages stated above.
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-whe
> n-deploying-ear-with-application-xml-tp4655362p4655796.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>


Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
guess i found the issue

currently the deploy used copy the deployed app in apps/ folder (in tomee)
so when undeploying it you need to give the apps/<app folder> path.

here the command i used:

./bin/tomee.sh deploy /tmp/testear/ear/target/eartest-0.0.1-SNAPSHOT.ear
./bin/tomee.sh undeploy /foo/apache-tomee/apps/eartest-0.0.1-SNAPSHOT


- Romain


2012/6/26 almos <al...@ukr.net>

> Sorry for not responding for quite long time on this.
>
> Yes, you are right, you need to use tomee.sh for that to reproduce the
> issue.
>
> Exact steps are:
>
> 1. Deploy application
>
> MBP-Almos:testear2 tomee.sh deploy /tmp/eartest-0.0.1-SNAPSHOT.ear
>
> 2. Check jsp page/servlet
>
> MBP-Almos:testear2 wget http://localhost:8080/frontend/test.jsp -O -
>
> <!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;
> &quot;http://www.w3.org/TR/html4/loose.dtd&quot;>
> <html>
> <head>
> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
> <title>Client</title>
> <body>
> test page
>
> </body>
>
> 3. Undeploy application
>
> tomee.sh undeploy
> /Work/java/apache-tomee-plus-1.0.0/apps/eartest-0.0.1-SNAPSHOT/
>
> 4. Check servlet/jsp page availability
>
> wget http://localhost:8080/frontend/test.jsp -O -
>
> <!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;
> &quot;http://www.w3.org/TR/html4/loose.dtd&quot;>
> <html>
> <head>
> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
> <title>Client</title>
> <body>
> test page
>
> </body>
>
> It's still available.
>
> Tries to access EJB results in the error messages stated above.
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655796.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Sorry for not responding for quite long time on this.

Yes, you are right, you need to use tomee.sh for that to reproduce the
issue.

Exact steps are:

1. Deploy application

MBP-Almos:testear2 tomee.sh deploy /tmp/eartest-0.0.1-SNAPSHOT.ear

2. Check jsp page/servlet

MBP-Almos:testear2 wget http://localhost:8080/frontend/test.jsp -O -

<!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;
&quot;http://www.w3.org/TR/html4/loose.dtd&quot;>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Client</title>
<body>
test page

</body>

3. Undeploy application 

tomee.sh undeploy
/Work/java/apache-tomee-plus-1.0.0/apps/eartest-0.0.1-SNAPSHOT/

4. Check servlet/jsp page availability

wget http://localhost:8080/frontend/test.jsp -O -

<!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;
&quot;http://www.w3.org/TR/html4/loose.dtd&quot;>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Client</title>
<body>
test page

</body>

It's still available.

Tries to access EJB results in the error messages stated above.

--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655796.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
hmm,

just tested and it seems fine with your sample...

any help to reproduce it?

PS: re-reading your mail i notice i didnt use tomee.sh, could it be the
issue?

- Romain


2012/6/14 almos <al...@ukr.net>

> Just discovered one more issue though ;).
>
> I have an EAR which is periodically gets deployed to TomEE from Jenkins.
> EAR consists WAR with JSP/Servlets and JAR with EJB components. First
> deploy
> goes always fine but after that issues start to appear.
>
> Here is a steps for reproduction for a problems I've discovered
>
> 0. TomEE started without any custom applications deployed
> 1. zz-1.0-SNAPSHOT.ear gets deployed to TomEE using tomee.sh deploy
> command,
> deploy goes fine
> 2. Everything works fine - servlets and EJBs
> 3. undeploy of zz-1.0-SNAPSHOT happens
> 4. [first problem] JSPs and Servlets are still accessible
> 5. zz-1.0-SNAPSHOT.ear gets deployed again
> 6. tomee.sh says deploy went well
> 7. JSP/Servlets are accessible
> 8. [second problem] any attempt to access EJB defined in the mentioned EAR
> gives exception:
>
> java.lang.IllegalStateException: Bean 'bmm/AuthBean' has been undeployed.
>
>
> org.apache.openejb.core.ivm.BaseEjbProxyHandler.getBeanContext(BaseEjbProxyHandler.java:568)
>
>
> org.apache.openejb.core.ivm.BaseEjbProxyHandler.isValidReference(BaseEjbProxyHandler.java:326)
>
>
> org.apache.openejb.core.ivm.BaseEjbProxyHandler.invoke(BaseEjbProxyHandler.java:224)
>        $Proxy69.authorize(Unknown Source)
>
>
> com.bmm.request.handlers.AuthenticateCommand.execute(AuthenticateCommand.java:27)
>        com.bmm.servlet.RequestHelper.perform(RequestHelper.java:30)
>        com.bmm.servlet.FrontServlet.doPost(FrontServlet.java:36)
>        javax.servlet.http.HttpServlet.service(HttpServlet.java:641)
>        javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655622.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Just discovered one more issue though ;).

I have an EAR which is periodically gets deployed to TomEE from Jenkins.
EAR consists WAR with JSP/Servlets and JAR with EJB components. First deploy
goes always fine but after that issues start to appear. 

Here is a steps for reproduction for a problems I've discovered

0. TomEE started without any custom applications deployed
1. zz-1.0-SNAPSHOT.ear gets deployed to TomEE using tomee.sh deploy command,
deploy goes fine
2. Everything works fine - servlets and EJBs
3. undeploy of zz-1.0-SNAPSHOT happens
4. [first problem] JSPs and Servlets are still accessible 
5. zz-1.0-SNAPSHOT.ear gets deployed again
6. tomee.sh says deploy went well
7. JSP/Servlets are accessible
8. [second problem] any attempt to access EJB defined in the mentioned EAR
gives exception:

java.lang.IllegalStateException: Bean 'bmm/AuthBean' has been undeployed.

org.apache.openejb.core.ivm.BaseEjbProxyHandler.getBeanContext(BaseEjbProxyHandler.java:568)

org.apache.openejb.core.ivm.BaseEjbProxyHandler.isValidReference(BaseEjbProxyHandler.java:326)

org.apache.openejb.core.ivm.BaseEjbProxyHandler.invoke(BaseEjbProxyHandler.java:224)
	$Proxy69.authorize(Unknown Source)

com.bmm.request.handlers.AuthenticateCommand.execute(AuthenticateCommand.java:27)
	com.bmm.servlet.RequestHelper.perform(RequestHelper.java:30)
	com.bmm.servlet.FrontServlet.doPost(FrontServlet.java:36)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:641)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:722)


--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655622.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Thanks, that worked fine.

--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655604.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
line 72, replace "for i in $TOMEE_HOME/webapps/tomee/lib/*.jar; do" by "for
i in $TOMEE_HOME/lib/*.jar; do"

- Romain


2012/6/10 almos <al...@ukr.net>

> Hi,
>
> Since I moved my EAR to apps/ folder everything was working great except
> hot
> deployment in that folder.
> I tried to:
> 1. simple EAR overwriting
> 2. using deploy tool bin/tomee.sh
> 3. googling a lot on some configuration options to add to the
> conf/tomee.conf
>
> Neither have given any satisfactory result ;).
>
> Unfortunately tomee.sh doesn't work on both Mac/Linux I tested on, every
> time it gives
>
> MBP-Almos:trunk alex$
> /Volumes/Work/java/apache-tomee-plus-1.0.0/bin/tomee.sh deploy
> /Work/java/BMM-0.0.1-SNAPSHOT.ear
> deploying /Work/java/BMM-0.0.1-SNAPSHOT.ear
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/openejb/cli/Bootstrap
> Caused by: java.lang.ClassNotFoundException:
> org.apache.openejb.cli.Bootstrap
>        at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>        at java.security.AccessController.doPrivileged(Native Method)
>        at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
>        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
>        at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>
> I have TOMEE_HOME/JAVA_HOME properly initialized so that shouldn't be a
> reason.
>
> So how can I switch hot deployment for the EAR located in apps/ directory?
>
> Thanks,
> Alex
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655544.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Hi,

Since I moved my EAR to apps/ folder everything was working great except hot
deployment in that folder.
I tried to:
1. simple EAR overwriting
2. using deploy tool bin/tomee.sh
3. googling a lot on some configuration options to add to the
conf/tomee.conf

Neither have given any satisfactory result ;).

Unfortunately tomee.sh doesn't work on both Mac/Linux I tested on, every
time it gives

MBP-Almos:trunk alex$
/Volumes/Work/java/apache-tomee-plus-1.0.0/bin/tomee.sh deploy
/Work/java/BMM-0.0.1-SNAPSHOT.ear
deploying /Work/java/BMM-0.0.1-SNAPSHOT.ear
Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/openejb/cli/Bootstrap
Caused by: java.lang.ClassNotFoundException:
org.apache.openejb.cli.Bootstrap
	at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

I have TOMEE_HOME/JAVA_HOME properly initialized so that shouldn't be a
reason.

So how can I switch hot deployment for the EAR located in apps/ directory?

Thanks,
Alex

--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655544.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Thanks for the support. Moving EAR to apps/ helped - everything works great
and no exceptions are thrown.

--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655434.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
seems it is fine if you deploy it in apps/ instead of webapps

- Romain


2012/6/5 almos <al...@ukr.net>

> Hi,
>
> Thanks for your response.
> I've prepared test package with maven build script.
>
> Link to download: http://www.4shared.com/zip/TGDORA0u/testear.html
> To package ear firstly setup environment variable DEPLOY_PATH where ear
> will
> be created and then run "mvn package".
>
> It fails on Tomee 1.0 with the exceptions I described.
> I'll check on the latest TomEE version as well and let you know.
>
>
> Thanks,
> Alex
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655430.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by almos <al...@ukr.net>.
Hi,

Thanks for your response.
I've prepared test package with maven build script.

Link to download: http://www.4shared.com/zip/TGDORA0u/testear.html
To package ear firstly setup environment variable DEPLOY_PATH where ear will
be created and then run "mvn package".

It fails on Tomee 1.0 with the exceptions I described.
I'll check on the latest TomEE version as well and let you know.


Thanks,
Alex

--
View this message in context: http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362p4655430.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Re: DuplicateDeploymentIdException when deploying ear with application.xml

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi,

first can you try the lastest snapshot please:
https://repository.apache.org/content/repositories/snapshots/org/apache/openejb/apache-tomee/1.1.0-SNAPSHOT/

do you put your ejbmodule in your webapp too?

any chance you share a sample to reproduce?

- Romain


2012/6/4 almos <al...@ukr.net>

> Hello,
>
> I am facing strange following problem when using application.xml in my EAR
> file.
>
> 1. I am using maven to build EAR which contains JAR with EJB components and
> one web application WAR
> 2. Maven automatically creates application.xml in the META-INF of my EAR
> 3. When deploying EAR on TomEE+ 1.0 deploy succeeds - web application and
> EJB's gets deployed and works fine but I get annoying exception in the log
> files:
>
> SEVERE: Unable to deploy collapsed ear in war /BMM-0.0.1-SNAPSHOT:
> Exception: Application cannot be deployed as it contains deployment-ids
> which are in use: app:
> /Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
>    Bean1
>    Bean2
>    Bean3
> org.apache.openejb.DuplicateDeploymentIdException: Application cannot be
> deployed as it contains deployment-ids which are in use: app:
> /Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
>    Bean1
>    Bean2
>    Bean3
>        at
>
> org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:540)
>        at
>
> org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:506)
>        at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:634)
>        at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:588)
>        at
>
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:117)
>        at
>
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>        at
>
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
>        at
>
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5161)
>        at
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>        at
>
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
>        at
> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
>        at
> org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
>        at
>
> org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
>        at
>
> org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
>        at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
>        at
> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>        at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
>        at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
>        at java.lang.Thread.run(Thread.java:680)
> 04.06.2012 18:18:25 org.apache.catalina.core.ContainerBase addChildInternal
> SEVERE: ContainerBase.addChild: start:
> org.apache.catalina.LifecycleException: Failed to start component
>
> [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/BMM-0.0.1-SNAPSHOT]]
>        at
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
>        at
>
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
>        at
> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
>        at
> org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
>        at
>
> org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
>        at
>
> org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
>        at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
>        at
> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>        at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
>        at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
>        at java.lang.Thread.run(Thread.java:680)
> Caused by: org.apache.tomee.catalina.TomEERuntimeException:
> org.apache.openejb.DuplicateDeploymentIdException: Application cannot be
> deployed as it contains deployment-ids which are in use: app:
> /Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
>    Bean1
>    Bean2
>    Bean3
>        at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:641)
>        at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:588)
>        at
>
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:117)
>        at
>
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>        at
>
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
>        at
>
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5161)
>        at
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>        ... 11 more
> Caused by: org.apache.openejb.DuplicateDeploymentIdException: Application
> cannot be deployed as it contains deployment-ids which are in use: app:
> /Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
>    Bean1
>    Bean2
>    Bean3
>        at
>
> org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:540)
>        at
>
> org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:506)
>        at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:634)
>        ... 17 more
> 04.06.2012 18:18:25 org.apache.catalina.startup.HostConfig deployDirectory
> SEVERE: Error deploying web application directory
> /Volumes/Work/java/apache-tomee-plus-1.0.0/webapps/BMM-0.0.1-SNAPSHOT
> java.lang.IllegalStateException: ContainerBase.addChild: start:
> org.apache.catalina.LifecycleException: Failed to start component
>
> [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/BMM-0.0.1-SNAPSHOT]]
>        at
>
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:898)
>        at
> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
>        at
> org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
>        at
>
> org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
>        at
>
> org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
>        at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
>        at
> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>        at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
>        at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
>        at java.lang.Thread.run(Thread.java:680)
>
>
>
>
>
> Generated application.xml looks following:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE application PUBLIC
>        &quot;-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN&quot;
>        &quot;http://java.sun.com/dtd/application_1_3.dtd&quot;>
> <application>
>  <display-name>BMM EAR module</display-name>
>  <module>
>    <ejb>backend-0.0.1-SNAPSHOT.jar</ejb>
>  </module>
>  <module>
>    <web>
>      <web-uri>frontend-0.0.1-SNAPSHOT.war</web-uri>
>      <context-root>/frontend</context-root>
>    </web>
>  </module>
> </application>
>
> So eventually after deploy succeeds TomEE unpacks EAR and it looks like
> that
> after unpack it tries to deploy it once more, however I am not sure.
>
> Does anybody seen this? How can I fix this or just disable EAR unpack in
> the
> web apps?
>
> Thanks,
> Alex
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/DuplicateDeploymentIdException-when-deploying-ear-with-application-xml-tp4655362.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>