This section covers how to configure the Parasoft JDBC Driver for JBoss.
JBoss application servers (including servers using PostgreSQL) can be configured as follows:
- Add the Parasoft module.
- Under
<JBOSS-INSTALL-DIR>/module
create the directoriescom/parasoft/main
. In the main directory, add ParasoftJDBCDriver.jar and the following module.xml file:
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <module xmlns="urn:jboss:module:1.0" name="com.parasoft"> <resources> <resource-root path="ParasoftJDBCDriver.jar"/> </resources> <dependencies> <module name="javax.api"/> <module name="original.module"/> </dependencies> </module>
Replace "original.module" with the name of your existing database module
For example, if you are using Postgres, replace
<module name="original.module"/>
with<module name="org.postgres"/>
- Under
Configure the standalone.xml drivers by adding the following driver xml fragment:
<driver name="parasoft" module="com.parasoft"> <driver-class>com.parasoft.xtest.jdbc.virt.driver.JDBCProxyDriver</driver-class> <xa-datasource-class>parasoft-vendor-specific-xa-datasource</xa-datasource-class> </driver>
More vendor-specific information:
See JDBC Driver Implementation Classes for additional information on vendor-specific driver implementation classes.
- Update the standalone.xml data source.
- Set the data source’s driver name to "parasoft".
- Update the connection-url as needed. Be sure to replace
host
,port
anddatabase
with the host, port and database of your server. For example:jdbc:parasoft:proxydriver:<original driver fully qualified class name>:@<original driver connection URL>
If you’re using PostgreSQL, this would be:jdbc:parasoft:proxydriver:org.postgresql.Driver:@jdbc:postgresql://host:port/database
- Configure the AUT’s startup parameters to use the Java system property
parasoft.virtualize.driver.proxy.direct=true
. - Configure the driver properties for the Parasoft JDBC Driver (for example,
virtualizeServerUrl
,virtualizeGroupId
). For details, see Driver/System Properties Required for All Environments.