Unable to dynamically set JPA datasource when creating entity manager factory in JBoss EAP
Issue
- Passing
javax.persistence.jtaDataSource
in the property map supplied to Persistence.createEntityManagerFactory(String, Map). - The value for the property is ignored and the default datasource (or one defined in the
persistence.xml
usingjta-data-source
ornon-jta-data-source
) is used instead.
Environment
- Red Hat JBoss Enterprise Application Platform (EAP) 7
- Hibernate 5
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.