I am using postgresql, JBoss 7.1 and J2EE6. My project structure has 1 ear with 1 JAR holding EJBs and 1 WAR holding the web front.
I am delivering the postgresql driver as JBoss module and changing the standalone.xml to reference the data source. With the above everything works fine.
Now I want to use arquillian to test against a jboss managed instance with postgres data source. I don't want to change the jboss that is downloaded by maven because I want to deliver all my dependencies within my application (The only thing acceptable would be the data source configuration inside standalone.xml on JBoss).
The problem:
If I start using postgresql jar inside EarContent/lib
of the ear
project I get missing/unsatisfied dependencies when starting jboss, looks like jboss can't locate the driver deployed inside standalone/deployments
.
Looking over the web ppl tell examples of how to use postgres driver with modules, but that is not what I want to do. I want to ship the postgresql driver along with the app so I have control over versions without much more effort (and I can test against postgres without adding the module to the jboss I will test against with arquillian).
How can I add the postgres driver to be shipped with my app without happening the missing/unsatisfied
dependencies error in JBoss?
If this is not possible, how can I change JBoss files without manually changing every time I do a clean
goal? Like modules and standalone.xml for example.