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" <[email protected]> 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. >
