i'm new to EJB 3 with jboss4.0.3SP1 but i'm not so new with the forums because i looked up my problem and i found the solution but seams that it not works:
in my @Stateful bean i write this:
protected EntityManager em;
and in persistence.xml i write :
this stuff is suppose to inject the em with an EntityManager but doesn'y work because all i get is NullPointException when i'm trying to use the em.
the server says(when i deploy the ear) : created entityManager with JNDI name:intranetFC_unitName
what i'm doing wrong ? i followed the exmples in EJB3.0 TrailBlaizer......
Same thing was happening to me. My question is how are you accessing the EJB bean? Are you simply making a call from a "non-ejb" class to your ejb class?