java - JPA EntityListener and persistence archive -
we've persistence archive containing entities , persistence.xml. , we've ejb module containing ejb stuff.
now specific use case need add entitylistener has access ejbs in service layer.
the ejb module depends on persistence module. declare listener in entity persistence module needs know class in ejb module. cyclic dependency not possible , having third module containing jpa listener leads cyclic dependencies well.
so option see merge ejb module , persistence archive single module. way loose flexibility use persistence archive in application connect remote interfaces without carrying whole ejb jar's content.
any ideas on how solve , stay modular (separate ejb , persistence modules?).
we're talking jee7 application.
you move persistence.xml
jpa project ejb project , use <jar-file>packedentity.jar</jar-file>
xml element. check answer.
Comments
Post a Comment