I'm trying to deploy an ear file twice on **Weblogic 220.127.116.11.0**. The applications are the same expect for context-root.
1. Same JPA models
2. Same persistance.xml (with same peristance-unit-name)
3. When I deploy "the second" ear and try to access to db from the first one I receive a
It seem that the first ear use its own models but the EntityManager of second one ear.
> java.lang.ClassCastException: com.myApplication.models.entityOne
> cannot be cast to com.myApplication.models.entityOne
Structure of my ear file is something like that:
Persistence.xml is defined as following:
Weblogic.xml is definied as following:
<persistence-unit name="my-persistance-unit" transaction-type="JTA">
I'm deploy twice my ear file because I want to replicate an issue that I received during paralell deploy in weblogic