[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Oracle Database resource problem

skumarsamy do-not-reply at jboss.com
Fri Jan 5 01:00:09 EST 2007


Hi,

I am looking for urgent help.
Im developing and deploying a new enterprise application with EJB3 and using oracle 10g as our database. Im using ojdbc14.jar for the library to be used for the database operations.

My jboss-ds.xml
<?xml version="1.0" encoding="UTF-8"?>

  <local-tx-datasource>
    <jndi-name>jdbc/OracleDS</jndi-name>
    <connection-url>jdbc:oracle:thin:@localhost:1521:orclrts</connection-url>
    <driver-class>oracle.jdbc.OracleDriver</driver-class>
    <user-name>appcrm</user-name>
    vsunjai
    <min-pool-size>5</min-pool-size>
    <max-pool-size>20</max-pool-size>
    <idle-timeout-minutes>5</idle-timeout-minutes>
  </local-tx-datasource>


My bean code as follows

@Resource(name = "jdbc/OracleDS", mappedName="java:jdbc/OracleDS")
    private void setJdbcOracleDS(DataSource ds) {
        this.jdbcOracleDS = ds;
    }
    
private DataSource jdbcOracleDS;

My resource aquiring class have
conn = jdbcOracleDS.getConnection();

It is saying the driver class as wrong.
If i change to oracle.jdbc.driver.OracelDriver then it works for some time and if i restart is says the oracle.jdbc.dirver.OracleDriver was wrong, i revert back then it is working.

As well when i try to close my result set it gives me nullpointerexception.

No idea of what is happening.
Will any one help to resolve this.

regards
kumar

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3998163#3998163

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3998163



More information about the jboss-user mailing list