I know how to bound the datasource.I use AS7.1
First at standalone.xml or domain.xml
<subsystem xmlns="urn:jboss:domain:datasources:1.0">
<datasources>
<datasource jndi-name="java:jboss/OracleDS" pool-name="OracleDS" enabled="true" jta="true" use-java-context="true" use-ccm="true">
<connection-url>
jdbc:oracle:thin:@*.*.*.:1521:*
</connection-url>
<driver>
oracle
</driver>
<transaction-isolation> TRANSACTION_READ_COMMITTED </transaction-isolation>
<pool>
<min-pool-size> 20 </min-pool-size>
<max-pool-size> 300</max-pool-size>
</pool>
<security>
<user-name>*</user-name>
<password>*</password>
</security>
<statement>
<prepared-statement-cache-size> 100 </prepared-statement-cache-size>
<share-prepared-statements/>
</statement>
</datasource>
<drivers>
<driver name="oracle" module="com.oracle.ojdbc14">
<driver-class>oracle.jdbc.OracleDriver</driver-class>
</driver>
</drivers>
</datasources>
</subsystem>
then remember to add folder like this: jboss-as-7.1.0.Final\modules\com\oracle\ojdbc14\main
in the "main" folder you must create module.xml and ojdbc14.jar
module.xml:
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.1" name="com.oracle.ojdbc14">
<resources>
<resource-root path="ojdbc14.jar"/>
<!-- Insert resources here -->
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.transaction.api"/>
</dependencies>
</module>
so, you can start the server, and input http://localhost:9990/ you can see the datasource:
Name JNDI Enabled?
java:jboss/OracleDS | OracleDS | true |
|
|
|
OK.
Areak.