2 Replies Latest reply on Mar 25, 2005 11:49 AM by bill.burke

    Hibernate/EJB 3 integration

    bill.burke

      I've been thinking about Hibernate and EJB3 integration a bit. What I want to support is both .hbm.xml files and EJB3 annotated entities within the same deployment and managed by the same EntityManager.

      THis is really easy to do as it just requires the EJB3 Deployer to look for .hbm.xml files and add them to the HBF Configuration object.


      If this is a good idea, we need to think about how XML annotation overrides will work. Specifically, the Hibernate Configuration class will need to support overlaying ejb-persistence.xml and .hbm.xml files on top of the annotation definitions...OR... the spec needs to forbid XML overlays/overriding for persistence.