Hi,

I am new to EJBs so I apologize if my question sounds silly. I am trying to 
configure Orion to use Oracle 8 and pooled connections.

This is how my data-source looks like:

    <data-source
       class="com.evermind.sql.ConnectionDataSource"
       ejb-location="jdbc/MyApollo"
       location="jdbc/OracleCoreDS"
          pooled-location="jdbc/OraclePooledDS"
       name="Oracle"
       schema="database-schemas/oracle.xml"
       xa-location="jdbc/xa/OracleXADS"
       connection-driver="oracle.jdbc.driver.OracleDriver"
       username="system"
       password="manager"
       url="jdbc:oracle:oci8:@APOLLO"
       inactivity-timeout="30"
    />

I am trying to implement a BMP and here is the code I am using to get the 
connection:

public void setEntityContext(EntityContext ec)
{
         ...
         Context initialContext = new InitialContext();
         ConnectionPoolDataSource dataSource = (ConnectionPoolDataSource) 
initialContext.lookup( "jdbc/OraclePooledDS" );
}

and later on

public Connection getConnection() throws SQLException
{
         ...
         return dataSource.getPooledConnection().getConnection();
}

I get the folowing exception in my client code when I create the bean

javax.ejb.EJBException: com.evermind.sql.OrionPooledDataSource
         at com.evermind.server.rmi.ba.invokeMethod(JAX)
         at com.evermind.server.rmi.a1.invoke(JAX)
         at com.evermind.server.rmi.a2.invoke(JAX)
         at __Proxy2.create(Unknown Source)
         at SelectTestClient.main(SelectTestClient.java:117)

that seems to be thrown
when the execution reaches the following line of code:
         ConnectionPoolDataSource dataSource = (ConnectionPoolDataSource) 
initialContext.lookup( "jdbc/OraclePooledDS" );

Thanks!
Danut


_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


Reply via email to