Situation: I have a WAR containing a persistence.xml, where a PU is defined and where the jta-data-source is set and points to a jdbc resource.
The issue I have is that I need multiple instances of this WAR for different purposes, and each of these instances should point to a different jdbc resource.
I am wondering if this is something that can be done at deploy-time (e.g. like deploying a war on a specific contextoor). Currently, I have to open the WAR, change the persistence.xml, rebuild it, and repeat this process for every instance. It would be nice if I can specify the jta-data-source of a persistence-unit at deploy time.
Any ideas?
[Message sent by forum member 'johanvos']
http://forums.java.net/jive/thread.jspa?messageID=474789