tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Gregg" <>
Subject RE: driver manager does not work neither giving error
Date Wed, 12 Jun 2002 16:06:58 GMT
I don't think Tomcat will recognize no matter where you put
it.  Rename it to classes12.jar and place it under
<tomcat-home>webapps/<project>/web-inf/lib, <tomcat-home>/lib, or
<tomcat-home>/common/lib.  If Tomcat can't find the driver class, I'd expect
a ClassNotFoundException in your localhost_log file.  Look in
<tomcat-home>/logs.  Try using a debugger or putting a try/catch around your

Also, if you're happy with hard-coding which db driver to use in your
application, don't bother with Class.forName(...).  It's purpose is to allow
your application to be unaware of the particular driver.  In that case you'd
do this:

String driverName = System.getProperty("driverName");
Class clazz = Class.forName(driverName);

Of course you'd give up the ability to use driver-specific extensions but
you could swap drivers and databases more easily.


-----Original Message-----
org]On Behalf Of Vikramjit Singh
Sent: Wednesday, June 12, 2002 2:39 AM
To: ''; JSP-INTEREST (E-mail)
Subject: driver manager does not work neither giving error


I am deploying my application from tomcat 3.2.1 to tomcat 4.0.3. I have
installed tomcat 4.0.3 and its working fine. I have a servlet which is
loaded on start up. The servlet is for connection pooling which opens the
connections. I am using oracle driver for connection pooling.

In my these lines are not being reached:

DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());

and after these  lines the connection pooling methods of Oracle driver is

neither is it throwing any error.

Since before these lines which ever code is there its working as the
system.out.println statements are being printed on the console. I know
Tomcat 4.0.3 has in built ConnectionPooling mechanism, hope thats not the
source of the problem. I am pretty much confused. Atleast it should throw an

Thanking in advance.

Vikramjit Singh,
Systems Engineer,
GTL Ltd.
Ph. 7612929-1031

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message