Currently I'm working on a Java webapp and we are using two databases: in-Mem database for unit tests and mysql for production. So we have two persistence units in the persistence.xml and we want to get the EntityManager instance depending on the maven build lifcycle phase (test: hsqldb, install: mysql). Is there any way to do that for example by injecting something?
Many thanks
Aucun commentaire:
Enregistrer un commentaire