[jboss-dev-forums] [Deployers on JBoss (Deployers/JBoss)] - Re: Ordering of .ear subdeployments

bstansberry@jboss.com do-not-reply at jboss.com
Thu Aug 10 16:39:45 EDT 2006


This change has broken the use case where a datasource is packaged in an ear with an ejb jar that use the datasource.

See http://jira.jboss.com/jira/browse/JBAS-3503 for the problem.  The testcase deploys test-cif.ear. The ear includes an ejb jar and a -ds.xml file for the datasource.  The ejbs fail to deploy due to the inability to find java:/CIFTestDS in JNDI.

Looking at the log, service jboss.jca:service=DataSourceBinding,name=CIFTestDS and the other
datasource related services are started *after* the ejbs, which explains
the failure.

My *guess* as to what is going on is the services are ordered based on their ordering within the deployment descriptors.  A side affect is those listed in application.xml come before those listed in jboss-app.xml.  The ds can only be listed in jboss-app.xml, so it comes later.  The JBAS-2904 work removed the subsequent comparator-based sorting that would have put the ds before the ejb jar.


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3964478#3964478

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3964478



More information about the jboss-dev-forums mailing list