|
From: Juergen H. <ju...@in...> - 2005-10-02 21:15:02
|
Yes... but I guess checking for the name starting with "oracle.jdbc." would be fine. It's just about checking whether the passed-in Connection has any chance of getting accepted by CLOB.createTemporary(con, ...) so we don't really need a full type check there - just a basic sanity check. Juergen _____ From: spr...@li... [mailto:spr...@li...] On Behalf Of Thomas Risberg Sent: Sunday, October 02, 2005 11:10 PM To: spr...@li... Subject: Re: [Springframework-developer] OracleLobHandler on WebSphere 6.0 We could also use the classloader for the connection to load any classes used for testing and for reflection - like conToUse.getClass().getClassLoader().loadClass(CONNECTION_CLASS_NAME); Thomas On Oct 2, 2005, at 4:58 PM, Thomas Risberg wrote: On Oct 2, 2005, at 4:43 PM, Juergen Hoeller wrote: So our OracleLobHandler works on the new "oracle.jdbc.Connection" interface, while WebSphere seems to return an "oracle.jdbc.driver.Connection" that's not assignable to the "oracle.jdbc.Connection" interface. The class we test for is: private static final String CONNECTION_CLASS_NAME = "oracle.jdbc.OracleConnection"; In my tests any Oracle connection is assignable to this class as long as they both come from the same classloader. Seems like the test is the problem here - maybe we should just test for a class name that starts with "oracle.jdbc" Thomas |