0 Replies Latest reply on May 9, 2013 11:27 AM by Honda ...

    Data Source jboss 7.1.1

    Honda ... Newbie

      i want validate connection before borrow from pool , i config data source as mention below but no validation happen before borrow connection from pool although i config validation in data source . so how can i config it to validate each connection .

       

      jboss version : 7.1.1

      Data Base  : Oracle 11

       

       

       

      <datasource jta="false" jndi-name="java:/OracleDS" pool-name="OracleDS" enabled="true" use-java-context="true" use-ccm="true">

                          <connection-url>jdbc:oracle:thin:@(DESCRIPTION =(ADDRESS = (PROTOCOL = TCP)(HOST = prod)(PORT = 1521)) (CONNECT_DATA =(SERVER = DEDICATED)(SERVICE_NAME = prod)))</connection-url>

                          <driver>oracleDriver</driver>

                          <pool>

                              <min-pool-size>10</min-pool-size>

                              <max-pool-size>100</max-pool-size>

                              <prefill>true</prefill>

                                                                  <flush-strategy>FailingConnectionOnly</flush-strategy>

                          </pool>

                          <security>

                              <user-name>name</user-name>

                              <password>pass</password>

                          </security>

                          <validation>

                              <valid-connection-checker class-name="org.jboss.jca.adapters.jdbc.extensions.oracle.OracleValidConnectionChecker"/>

                              <check-valid-connection-sql>select 1 from dual</check-valid-connection-sql>

                              <validate-on-match>true</validate-on-match>

                              <background-validation>false</background-validation>

                              <stale-connection-checker class-name="org.jboss.jca.adapters.jdbc.extensions.oracle.OracleValidConnectionChecker"/>

                              <exception-sorter class-name="org.jboss.jca.adapters.jdbc.extensions.oracle.OracleExceptionSorter"/>

                          </validation>

                          <timeout>

                              <blocking-timeout-millis>5000</blocking-timeout-millis>

                              <idle-timeout-minutes>1</idle-timeout-minutes>

                          </timeout>

                          <statement>

                              <track-statements>true</track-statements>

                          </statement>

                      </datasource>

                      <drivers>

                          <driver name="oracleDriver" module="com.oracle.ojdbc6">

                              <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>

                          </driver>

                      </drivers>

                  </datasources>

       

       

       

       

      thanks in advance ,

      ' اختر 1 من المزدوجة ' موجود