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:
I use this configuration and I am able to deploy multiple Seam application. Maybe someone could post a better solution.
I hope it helps.
Hi - thx Joao,
yes - I have already tried this. Unfortunately it doesn't help. :-(
Have you checked that no sub-war:s or other archives defines colliding names for classloaders?
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:
and these are my jboss-app.xmls
<jboss-app> <loader-repository> seam.jboss.org:loader=app1-ear <loader-repository-config> java2ParentDelegation=false </loader-repository-config> </loader-repository> </jboss-app>
<jboss-app> <loader-repository> seam.jboss.org:loader=app2-ear <loader-repository-config> java2ParentDelegation=false </loader-repository-config> </loader-repository> </jboss-app>
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.
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?
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.
Yeah - that was our solution, too. Sorry for not posting it here.
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
any ideas ??
thanks a lot for your help
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