You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by renz <re...@areasante.com> on 2015/05/28 14:26:05 UTC

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Hello,

It seems like the problem is still present in 1.7.2 release.

My tomee.xml contains :


I've tried with and without "tomee.unpack.dir=work" in system.properties.

Did I miss something?

Thank you.



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675071.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by renz <re...@areasante.com>.
I've tried the SNAPSHOT and don't have any "duplicate" issues but now I have
some weird things when my application is reloaded (startup, copy EAR into
apps/, remove EAR from apps/, copy EAR into apps/).

1. I deploy my app and call it for the first time. My remote EJB fetch
something in a database and test if the object is an instance of
org.postgresql.util.PGobject :


2. The first time the app is launched, the test returns TRUE which is what I
expect.

3. I reload my app without restarting Tomee

4. This time the test fails but the debug line print : "myObject.class =
org.postgresql.util.PGobject"


I don't understand what can cause this. I'm not very about classloading and
other stuff like this.
Of course if I restart TomEE everythings works fine.

Do you have any idea?

Thank you




--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675215.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by Romain Manni-Bucau <rm...@gmail.com>.
https://repository.apache.org/content/groups/snapshots/org/apache/openejb/apache-tomee/1.7.3-SNAPSHOT/
pick the last one


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com>

2015-06-04 9:05 GMT-07:00 renz <re...@areasante.com>:

> I would test you're fix but I don't know how to get a SNAPSHOT.
> Should I build it from source
> (http://tomee.apache.org/dev/source-code.html)?
>
> Forgive my ignorance :-p
>
>
>
> --
> View this message in context:
> http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675155.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by renz <re...@areasante.com>.
I would test you're fix but I don't know how to get a SNAPSHOT.
Should I build it from source
(http://tomee.apache.org/dev/source-code.html)?

Forgive my ignorance :-p



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675155.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by renz <re...@areasante.com>.
Thank you.
I'll test it tomorrow ;-)



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675147.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

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

created https://issues.apache.org/jira/browse/TOMEE-1596, pushed a fix
which should be available tomorrow on snapshots, feedback welcomed


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com>

2015-06-03 15:01 GMT+02:00 renz <re...@areasante.com>:

> When TomEE is running and then I drop the EAR, it's OK.
> The problem only occurs when I restart TomEE with the EAR already in
> "apps".
>
>
>
>
> --
> View this message in context:
> http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675143.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by renz <re...@areasante.com>.
When TomEE is running and then I drop the EAR, it's OK.
The problem only occurs when I restart TomEE with the EAR already in "apps".




--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675143.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by Romain Manni-Bucau <rm...@gmail.com>.
thing I got what is wrong,if you deploy with the container the logic has an
issue, do you care testing manually dropping the ear once the container
runs to confirm it?


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com>

2015-06-03 11:57 GMT+02:00 renz <re...@areasante.com>:

> Here's a multimodule project :  testAutoDeployEar.zip
> <
> http://tomee-openejb.979440.n4.nabble.com/file/n4675138/testAutoDeployEar.zip
> >
> - test-commons : Remote Interface
> - test-ejb : EJB Module
> - test-ear : EAR Module
>
> Just run :
> - mvn clean install    (on parent POM)
> - mvn tomee:run      (on test-ear POM)
>
> I've only changed tomee.xml to enable "autoDeploy".
>
> Thank you
>
>
>
>
>
>
> --
> View this message in context:
> http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675138.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by renz <re...@areasante.com>.
Here's a multimodule project :  testAutoDeployEar.zip
<http://tomee-openejb.979440.n4.nabble.com/file/n4675138/testAutoDeployEar.zip>  
- test-commons : Remote Interface
- test-ejb : EJB Module 
- test-ear : EAR Module

Just run :
- mvn clean install    (on parent POM)
- mvn tomee:run      (on test-ear POM)

I've only changed tomee.xml to enable "autoDeploy".

Thank you






--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675138.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by Romain Manni-Bucau <rm...@gmail.com>.
reproduce it with tomee maven plugin or a script cause it is surely linked
to something specific to your setup (or our setup in tests)


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com>

2015-06-02 8:49 GMT-07:00 renz <re...@areasante.com>:

> "work" is my "tomee.unpack.dir".
> But the problem is the same if I don't set "tomee.unpack.dir" in
> system.properties
>
> How can I prevent "org.apache.openejb.DuplicateDeploymentIdException:
> Application cannot be deployed as it contains deployment-ids which are in
> use" on tomee restart?
>
>
>
> --
> View this message in context:
> http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675127.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by renz <re...@areasante.com>.
"work" is my "tomee.unpack.dir".
But the problem is the same if I don't set "tomee.unpack.dir" in
system.properties

How can I prevent "org.apache.openejb.DuplicateDeploymentIdException:
Application cannot be deployed as it contains deployment-ids which are in
use" on tomee restart?



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675127.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by Romain Manni-Bucau <rm...@gmail.com>.
shouldnt be needed if work is not a deployment folder


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com>

2015-06-02 8:08 GMT-07:00 renz <re...@areasante.com>:

> Actually, the problem happens when I restart Tomee (bin/shutdown.sh then
> bin/startup.sh), with my ear in "apps/" and the unpacked ear in "work/".
> Should I clean "work/" directory on tomee startup/shutdown?
>
> Thank you
>
>
>
> --
> View this message in context:
> http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675123.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: TomEE 1.7.1 Duplicate App Deployment when autoDeploy="true"

Posted by renz <re...@areasante.com>.
Actually, the problem happens when I restart Tomee (bin/shutdown.sh then
bin/startup.sh), with my ear in "apps/" and the unpacked ear in "work/".
Should I clean "work/" directory on tomee startup/shutdown?

Thank you



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/TomEE-1-7-1-Duplicate-App-Deployment-when-autoDeploy-true-tp4673900p4675123.html
Sent from the TomEE Users mailing list archive at Nabble.com.