Dyego Souza Dantas Leal wrote:
> I have a big problem...
>
>
> I have an EJB3 app called "UserAndGroups" deployed on my GlassFish
> server...
>
>
> and now , i wroted an another app to interate with this application...
> BUT one session on "UserAndGroups" returns a "User" POJO, and i will
> manipulate it on my new app..
> If i add the User.class on my new app , the container try to load
> EntityBean User (beacause have a @Entity annotation), but the Entity
> Bean User is already loaded on "UserAndGroups" EAR
>
> Is there a way for disable load of User Entity Bean in new app ?
>
An instance of the User class in your new app shouldn't be considered
an entity unless your new app has a persistence.xml file *and* you
use the EntityManager to load the class. Otherwise, it should just
be treated as a POJO in your new app.