geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Jencks (JIRA)" <...@geronimo.apache.org>
Subject [jira] Created: (GERONIMO-765) DriverManager is totally unsuited to enterprise software, and use in tranql-connector causes classloader problems
Date Sat, 16 Jul 2005 00:39:13 GMT
DriverManager is totally unsuited to enterprise software, and use in tranql-connector causes
classloader problems
-----------------------------------------------------------------------------------------------------------------

         Key: GERONIMO-765
         URL: http://issues.apache.org/jira/browse/GERONIMO-765
     Project: Geronimo
        Type: Bug
  Components: connector  
    Versions: 1.0-M3    
    Reporter: David Jencks
 Assigned to: David Jencks 


DriverManager will not connect to drivers that aren't in the classloader of the code that
calls DriverManager.  This makes use of tranql connector tricky in scenarios such as the following:

config 1 uses tranql connector, connects to some db.

config 2, child of config 1, uses tranql connector, tries to use a different driver.  DriverManager
reports it cannot find a suitable driver for the URL.  The tranql connector class that is
calling DriverManager is in a parent classloader of the driver.

possible solutions:

1) rearrange configurations so you never have tranql connector in your parent classloader.
2) write more tranql connector classes that use datasource and pooled datasource implementations
3) dynamically generate a class at runtime in the driver's classloader or a child classloader
that calls DriverManager.

In order of desirability, I'd say 2, 1, 3, but I think we have to investigate (3) since this
problem is just about impossible to diagnose.

Thanks to Dan Debrunner for pointing out this "feature" of DriverManager.



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message