My current environment uses Linux, CentOS, WildFly 16. There are multiple datasources and it is all established externally in the standalone.xml. The application(s) in WildFly work just fine.
The issue I am dealing with is when I deploy the war file using command line interface (./bin/jboss-cli.sh
) the application will use the existing datasource and I would like to change the datasource. For example App1.war uses MySqlDS1 datasource and App2_test.war uses MySqlDS2 datasource. I plan to overwrite App1.war with App2_test.war. The code will be mv App2_test.war App1.war
. At that time the App1.war will be pointed to MySqlDS2 datasource, I believe since it now contains the App2_test code - that is the issue.
I need to change the App2_test.war file to point to MySqlDS1. I need to find the file that associates the URL to the datasource in the standalone.xml - I believe. I looked into web.xml but it does not exist in my war file and may not be provided in releases above EAP 6. I also looked into jboss-web.xml but unable to find file. I only have Manifest.mf in /META-INF and nothing in /WEB-INF/lib.
What file needs to be updated?