If you ever created an EJB application using older versions of JEE specifications, J2EE, you would remember that data persistence was achieved using Entity Beans, which implemented the
javax.ejb.EntityBean interface, and you had to implement all those horrifying methods and provide different implementations, depending on the persistence nature of the entity bean, that is container-managed or bean-managed.
In the JPA world, the Entity Manager represents the persistence unit. It is defined by the
javax.persistence.EntityManager interface. This is the JPA API that is your gateway to the persistence store, just as the Hibernate Session is when working directly through the Hibernate API. In EJB3, you will need to declare the persistence unit and let the application server know who...