4 Replies Latest reply on Sep 29, 2014 7:57 AM by bajajb

    java.lang.NoSuchMethodException: org.jboss.jca.adapters.jdbc.jdk6.WrappedConnectionJDK6.getPhysicalConnection()

    bajajb

      Hi Everybody,

       

      I am using a simple Jsp Servlet model and Oracle Database for my project. I have currently migrated my application from Websphere to Jboss Eap 6.1.1 and since then I am encountering

      java.lang.NoSuchMethodException: org.jboss.jca.adapters.jdbc.jdk6.WrappedConnectionJDK6.getPhysicalConnection()  whenever I am trying to Update a particular Form. Interesting fact is that this error appears only in Dev environment. In my local that form does not appear anyway. That time it is showing following error in stack trace:

       

      00:08:41,024 WARN

      [org.jboss.jca.core.connectionmanager.pool.strategy.OnePool]

      (http-localhost/127.0.0.1:8080-3) IJ000612: Destroying connection that could not be successfully matched:

      org.jboss.jca.core.connectionmanager.listener.TxConnectionListener@7314c9dd

      [state=NORMAL managed

      connection=org.jboss.jca.adapters.jdbc.local.LocalManagedConnection@4a8464c5

      connection handles=0 lastUse=1411670250572 trackByTx=false

      pool=org.jboss.jca.core.connectionmanager.pool.strategy.OnePool@39d0cc70

      pool internal context=SemaphoreArrayListManagedConnectionPool@3b1deab7

      [pool=project_ds] xaResource=LocalXAResourceImpl@39f3e7bb[connectionListener

      =7314c9dd connectionManager=15ba5129 warned=false currentXid=null productName=Oracle productVersion=Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options jndiName=java:/jdbc/project_ds] txSync=null]

      00:08:46,899 WARN

      [org.jboss.jca.core.connectionmanager.pool.strategy.OnePool]

      (http-localhost/127.0.0.1:8080-7) IJ000612: Destroying connection that could not be successfully matched:

      org.jboss.jca.core.connectionmanager.listener.TxConnectionListener@1bb632d8

      [state=NORMAL managed

      connection=org.jboss.jca.adapters.jdbc.local.LocalManagedConnection@74c9fc32

      connection handles=0 lastUse=1411670321242 trackByTx=false

      pool=org.jboss.jca.core.connectionmanager.pool.strategy.OnePool@39d0cc70

      pool internal context=SemaphoreArrayListManagedConnectionPool@3b1deab7

      [pool=project_ds] xaResource=LocalXAResourceImpl@78cc7284[connectionListener

      =1bb632d8 connectionManager=15ba5129 warned=false currentXid=null productName=Oracle productVersion=Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options jndiName=java:/jdbc/project_ds] txSync=null]

       

      Any help will be highly appreciated. Thanks in Advance.

      Thanks,

      Barsha

        • 1. Re: java.lang.NoSuchMethodException: org.jboss.jca.adapters.jdbc.jdk6.WrappedConnectionJDK6.getPhysicalConnection()
          wdfink

          Could you add a bit more details how the code look like and how you installed the datasource and driver?

          • 2. Re: java.lang.NoSuchMethodException: org.jboss.jca.adapters.jdbc.jdk6.WrappedConnectionJDK6.getPhysicalConnection()
            bajajb

            Hi,

            The code runs absolutely fine in WebSphere so there must be wrong during Driver/Data Source installation.I have added Ojdbc6.jar and module.xml files inside jbossEap/modules/systems/layers/com/oracle/ojdbc6/main folder.

             

            Module.xml:

            <?xml version.../>

            <module name=...../>

            <resources><resource-root-path="ojdbc6.jar"/> </resources>

            <dependencies> <module- name="javax.api" /> </dependencies>

             

            I executed jboss-cli.bat file after executing add-user.bat file (for setting admin user) in cli and able to log in to JDS Eap Console and there added data source- 'project_ds'. Is there anything wrong? Waiting for your reply.

            • 3. Re: java.lang.NoSuchMethodException: org.jboss.jca.adapters.jdbc.jdk6.WrappedConnectionJDK6.getPhysicalConnection()
              wdfink

              How do you add the datasource and how your module name look like.

              Also did you see the datasource startup within the logfile?

              • 4. Re: java.lang.NoSuchMethodException: org.jboss.jca.adapters.jdbc.jdk6.WrappedConnectionJDK6.getPhysicalConnection()
                bajajb

                Hi,

                Please take a look into the excerpts from Standalone.xml where I declared datasource. I am using ojdbc6.jar. (code is compiled using Jdk1.7).

                <datasources>

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

                <connection-url>jdbc:oracle:thin:@servername:port:sid</connection-url>

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

                <driver>oracle</driver>

                <pool>

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

                <allow-multiple-users>true</allow-multiple-users></pool>

                <security><user-name>aa</user-name>

                <password>aa</password>

                </security>-<validation><validate-on-match>false</validate-on-match><background-validation>false</background-validation></validation>-<timeout><idle-timeout-minutes>1800</idle-timeout-minutes></timeout>-<statement><share-prepared-statements>false</share-prepared-statements></statement></datasource>

                .

                .

                .

                </datasource>

                <drivers>

                <driver module="com.oracle.ojdbc6" name="oracle"><xa-datasource-class>oracle.jdbc.OracleDriver</xa-datasource-class></driver></drivers></datasources>

                 

                and Yeah I could see the datasource startup in Jboss Console.

                I could not understand what is causing this error.

                Waiting for your reply.

                Thanks.

                Barsha