1 Reply Latest reply on Oct 9, 2013 9:33 AM by cfranco Franco

    pingDatabase on Oracle driver is locked

    ducheol kim Newbie

      Hi All.

      I use JDK6.0, jboss5.1.0.GA & Oracle 10g.

       

      We use XADatasource supported by jboss.

      To prevent some pooling issue we configured to check whether connection is valid or not by adding "OracleValidConnectionChecker".

      After that, our system show some strange behavior.

       

      If there is some idle time, system is hangup.

      I check it by jconsole, and found that thread is execute so long time.

      I execute threaddump , and got below message.

       

      "WorkerThread#2[10.75.50.14:38937]" - Thread t@259

         java.lang.Thread.State: RUNNABLE

      at java.net.SocketInputStream.socketRead0(Native Method)

      at java.net.SocketInputStream.read(SocketInputStream.java:129)

      at oracle.net.ns.Packet.receive(Unknown Source)

      at oracle.net.ns.DataPacket.receive(Unknown Source)

      at oracle.net.ns.NetInputStream.getNextPacket(Unknown Source)

      at oracle.net.ns.NetInputStream.read(Unknown Source)

      at oracle.net.ns.NetInputStream.read(Unknown Source)

      at oracle.net.ns.NetInputStream.read(Unknown Source)

      at oracle.jdbc.driver.T4CMAREngine.unmarshalUB1(T4CMAREngine.java:1099)

      at oracle.jdbc.driver.T4CMAREngine.unmarshalSB1(T4CMAREngine.java:1070)

      at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:478)

      at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:207)

      at oracle.jdbc.driver.T4CStatement.executeForDescribe(T4CStatement.java:790)

      at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1039)

      at oracle.jdbc.driver.T4CStatement.executeMaybeDescribe(T4CStatement.java:830)

      at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1132)

      at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:1272)

      - locked oracle.jdbc.driver.T4CStatement@d06187

      - locked oracle.jdbc.driver.T4CConnection@a47d399

      at oracle.jdbc.driver.PhysicalConnection.pingDatabase(PhysicalConnection.java:4366)

      at oracle.jdbc.OracleConnectionWrapper.pingDatabase(OracleConnectionWrapper.java:360)

      at sun.reflect.GeneratedMethodAccessor294.invoke(Unknown Source)

      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

      at java.lang.reflect.Method.invoke(Method.java:597)

      at org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker.isValidConnection(OracleValidConnectionChecker.java:70)

       

      According to above message , DBPooling validation method is blocked.

      At that time , there isn’t any working thread and JVM only use about 100M memory.

      I ask DBA whether there is any issue on db side, but he said there isn't any error message on db & listener.

       

      Is there any person who have a experience like this ?

       

      Below is datasource configuration.

       

      <xa-datasource>   

      <jndi-name>jdbc/SOURCE_NAME</jndi-name>   

      <track-connection-by-tx>true</track-connection-by-tx>   

      <valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker</valid-connection-checker-class-name>   

      <isSameRM-override-value>false</isSameRM-override-value>   

      <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>   

      <xa-datasource-property name="URL">jdbc:oracle:thin:@XXX.XXX.XXX.XXX:1521:SID</xa-datasource-property>   

      <xa-datasource-property name="User">XXXX</xa-datasource-property>   

      <xa-datasource-property name="Password">XXXX</xa-datasource-property>   

      <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>

      <new-connection-sql>alter session set nls_date_format='YYYY-MM-DD HH24:MI:SS' nls_comp='LINGUISTIC' nls_sort='BINARY_CI'</new-connection-sql>

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

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

       

      <no-tx-separate-pools/>

      <isSameRM-override-value>false</isSameRM-override-value>

      </xa-datasource>