1 Reply Latest reply on Dec 4, 2007 4:50 AM by jaikiran pai

    Apparently wrong driver class specified for URL: class

    Dip sd Newbie

      Hi,

      I m trying to get datasource connection using jboss 4.0.4 & oracle 10g. I have my EJB connecting to database. For

      this I have followed following steps,

      1. Placed this EJB.jar in Ear.ear file
      2. Added ojdbc14.jar from 10g into EAR file
      3. Updated MANIFEST.MF of EJB.jar to refer to ojdbc14.jar
      4. Created 'jboss-app.xml' in 'Ear\Meta-Inf' folder to create class loader
      5. Content of 'jboss-app.xml' are as follows,
      <?xml version="1.0" encoding="UTF-8"?>
      <jboss-app>
      <loader-repository>
      loader=MYCL
      </loader-repository>
      </jboss-app>
      6. When I try to deploy this EAR file, I'm getting following error,

      20:42:56,559 WARN [JBossManagedConnectionPool] Throwable while attempting to get a new connection: null
      org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable:

      (org.jboss.resource.JBossResourceException: Apparently wrong driver class specified for URL: class:

      oracle.jdbc.driver.OracleDriver, url: jdbc:oracle:thin:@3.96.199.229:1521:atlord32)
      at

      org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFact

      ory.java:179)
      at

      org.jboss.resource.connectionmanager.InternalManagedConnectionPool.createConnectionEventListener(InternalManagedConne

      ctionPool.java:565)
      at

      org.jboss.resource.connectionmanager.InternalManagedConnectionPool.getConnection(InternalManagedConnectionPool.java:25

      0)
      at

      org.jboss.resource.connectionmanager.JBossManagedConnectionPool$BasePool.getConnection(JBossManagedConnectionPool.j

      ava:529)
      at

      org.jboss.resource.connectionmanager.BaseConnectionManager2.getManagedConnection(BaseConnectionManager2.java:341)
      at

      org.jboss.resource.connectionmanager.TxConnectionManager.getManagedConnection(TxConnectionManager.java:301)
      at

      org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:396)
      at

      org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectio

      nManager2.java:842)
      at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:88)
      at org.apache.commons.dbutils.QueryRunner.prepareConnection(QueryRunner.java:195)
      at org.apache.commons.dbutils.QueryRunner.query(QueryRunner.java:306)
      at org.apache.commons.dbutils.QueryRunner.query(QueryRunner.java:328)

      7. When I add ojdbc14.jar in classpath or server\lib directory, it's working fine. what could be causing this?

      Thanks in advance for help