Must every Entity Bean be registered in persistence.xml?

后端 未结 3 1592
北海茫月
北海茫月 2021-02-20 07:49

I\'m using Eclipse Facets for JPA 2.0 and Hibernate 4.2 implementation. I think I recall that in previous project I would not have to register an Entity Bean in the persistence.

3条回答
  •  温柔的废话
    2021-02-20 08:29

    in jpa you have to compile a file called persistence.xml where you tell Hibernate which classes will be managed by your ORM.
    Check this question and its accepted answer

提交回复
热议问题