You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Fabbri Michele <Mi...@cedaf.it> on 2006/01/26 12:49:47 UTC

R: [SPAM_KeyWord_] - Re: Problem with OJB and Oracle9i - Found word(s) list error in the Text body

I'm using Tomcat 5.0.x which use DBCP, I set accessToUnderlyingConnectionAllowed in server.xml but doesn't work: 


    <ResourceParams name="people/LegacyDB">
	<parameter>
	<name>accessToUnderlyingConnectionAllowed</name>
	<value>true</value>
  	</parameter>    
      <parameter>  
        <name>factory</name>  
        <value>org.apache.commons.dbcp.BasicDataSourceFactory</value>  
      </parameter>      
      <parameter>
        <name>url</name>
        <value>jdbc:oracle:thin:@ORA9.CEDAFPRIV.IT:1521:ora9</value>
      </parameter>

My OJB.properties is:

#ConnectionFactoryClass=org.apache.ojb.broker.accesslayer.ConnectionFactoryPooledImpl

#ConnectionFactoryClass=org.apache.ojb.broker.accesslayer.ConnectionFactoryNotPooledImpl

ConnectionFactoryClass=org.apache.ojb.broker.accesslayer.ConnectionFactoryManagedImpl

#ConnectionFactoryClass=org.apache.ojb.broker.accesslayer.ConnectionFactoryDBCPImpl





I try to set:

ConnectionFactoryClass=org.apache.ojb.broker.accesslayer.ConnectionFactoryDBCPImpl

But nothing happen.


Thank you
Michele


-----Messaggio originale-----
Da: Armin Waibel [mailto:arminw@apache.org] 
Inviato: giovedì 26 gennaio 2006 11.22
A: OJB Users List
Oggetto: [SPAM_KeyWord_] - Re: Problem with OJB and Oracle9i - Found word(s) list error in the Text body

Hi Michele,

from your first posted stack trace it seems that you are using DBCP.

 > org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper
 > with modifiers "public"

Did you set the 'accessToUnderlyingConnectionAllowed' flag to true? If 
not please give it a break.

regards,
Armin

Fabbri Michele wrote:
> Thank you for the advice,
> I used the last jdbc driver 10.2.0.1.0 from Oracle and I set level 3 in jdbc-connection-descriptor but I have the same error:
> 
> 56422 [http-8080-Processor24] DEBUG org.apache.ojb.broker.platforms.PlatformOracle9iImpl  - genericUnwrap failed
> java.lang.IllegalAccessException: Class org.apache.ojb.broker.platforms.PlatformOracle9iImpl can not access a member of class org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper with modifiers "public"
> 	at sun.reflect.Reflection.ensureMemberAccess(Reflection.java:57)
> 	at java.lang.reflect.Method.invoke(Method.java:317)
> 	at org.apache.ojb.broker.platforms.PlatformOracle9iImpl.genericUnwrap(Unknown Source)
> 
> 
> I don't understand how ojb can unwrap connection from class org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper if the class is private.
> 
> Michele
> 
> 
> 
> 
> -----Messaggio originale-----
> Da: Thomas Dudziak [mailto:tomdzk@gmail.com] 
> Inviato: mercoledì 25 gennaio 2006 20.25
> A: OJB Users List
> Oggetto: Re: Problem with OJB and Oracle9i
> 
> On 1/25/06, Fabbri Michele <Mi...@cedaf.it> wrote:
> 
>> I have a poblem using OJB 1.0.3 with Oracle9i, when I try to connect to
>> datasource defined with jndi in tomcat 5, if I define the datasource in
>> repository it works.
> 
> I'm no Oracle expert, so I'm not sure whether it helps, but you could
> try the newest JDBC driver (I think 10.0.2 is the latest), and use
> JDBC level 3 in the jdbc-connection-descriptor.
> 
> Tom
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org