-
1. Re: Deploy multiple Seam-EARs to a single JBoss AS
joaobmonteiro Oct 28, 2008 5:46 PM (in response to mikeschulze)Hi Mike,
Yes, your problem is all about classloaders. I am not a JBoss AS expert so my advice could not be the better one but one thing you can do is treat each app as isolated ear. For this, in ear-deployer.xml set the Isolated atribute:
<attribute name=”Isolated”>true</attribute>
I use this configuration and I am able to deploy multiple Seam application. Maybe someone could post a better solution.
I hope it helps.
-
2. Re: Deploy multiple Seam-EARs to a single JBoss AS
mikeschulze Oct 28, 2008 6:11 PM (in response to mikeschulze)Hi - thx Joao,
yes - I have already tried this. Unfortunately it doesn't help. :-(
-
3. Re: Deploy multiple Seam-EARs to a single JBoss AS
obfuscator Oct 28, 2008 7:52 PM (in response to mikeschulze)Have you checked that no sub-war:s or other archives defines colliding names for classloaders?
-
4. Re: Deploy multiple Seam-EARs to a single JBoss AS
mikeschulze Oct 29, 2008 9:33 AM (in response to mikeschulze)There are no other apllications deployed then my two EARs. As I mentioned - if I undeploy one of those - the other EAR works just fine.
In the JMX-console of my JBoss I can see, that there are two different LoaderRepositories:
org.jboss.mx.loading.HeirarchicalLoaderRepository3@1d0bc85 org.jboss.mx.loading.HeirarchicalLoaderRepository3@198c0b5
and these are my jboss-app.xmls
EAR1:
<jboss-app> <loader-repository> seam.jboss.org:loader=app1-ear <loader-repository-config> java2ParentDelegation=false </loader-repository-config> </loader-repository> </jboss-app>
EAR2:
<jboss-app> <loader-repository> seam.jboss.org:loader=app2-ear <loader-repository-config> java2ParentDelegation=false </loader-repository-config> </loader-repository> </jboss-app>
-
5. Re: Deploy multiple Seam-EARs to a single JBoss AS
ppalazon.ppalazon.dsi.uclm.es Oct 29, 2008 7:04 PM (in response to mikeschulze)It's possible that you have 2 jars with same classes?. If you have the same classes with same qualify-name, classloader don't know what class get.
-
6. Re: Deploy multiple Seam-EARs to a single JBoss AS
austin Feb 10, 2009 5:20 AM (in response to mikeschulze)Hi Mike,
I am now facing exactly the same problem with Seam 2.1.1.GA running on Jboss 4.2.3.GA AS. Did you solve this problem?
Best regards,
Austin -
7. Re: Deploy multiple Seam-EARs to a single JBoss AS
austin Feb 10, 2009 6:02 AM (in response to mikeschulze)I figured out where the problem is right after posting. The problem is caused by the same jndi-name of EntityManagerFactory. Just modify the persistence.xml and components.xml and makes the jndiName of EntityManagerFactory(s) different.
Hope this helps.
Austin -
8. Re: Deploy multiple Seam-EARs to a single JBoss AS
mikeschulze Feb 10, 2009 2:42 PM (in response to mikeschulze)Yeah - that was our solution, too. Sorry for not posting it here.
Mike
-
9. Re: Deploy multiple Seam-EARs to a single JBoss AS
jmiguel77 Nov 30, 2009 7:13 PM (in response to mikeschulze)Hi
i have tried the solutions exposed here but with no success
- i changed the ear-deployer.xml file with Isolation=true
- i have changed the jboss-app.xml of the ears in the way described here
- the EntityManagerFactory of each ear has a differente JNDI name
nevertheless i am getting this exception:
Caused by: java.lang.ClassNotFoundException: No ClassLoaders found for: org.jboss.seam.framework.EntityHome
at org.jboss.mx.loading.LoadMgr3.beginLoadTask(LoadMgr3.java:212)
at org.jboss.mx.loading.RepositoryClassLoader.loadClassImpl(RepositoryClassLoader.java:521)
at org.jboss.mx.loading.RepositoryClassLoader.loadClass(RepositoryClassLoader.java:415)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
any ideas ??
thanks a lot for your help -
10. Re: Deploy multiple Seam-EARs to a single JBoss AS
jmiguel77 Nov 30, 2009 7:15 PM (in response to mikeschulze)i don't know if this would be of any importance, but i have some flex development inside those ears; i am using flamingo to make the seam / flex binding