-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Alan,

Alan Chandler wrote:
> In particular, I have NO contexts in my $CATALINA_HOME/conf/server.xml, 
> since I want to bring these in in my webapps .war file.

Good.

> So in the .war file for my app I have a META-INF/context.xml file with 
> the following in (apart from the password which I have changed)
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <Context docBase="usermgr" path="/usermgr">

Get rid of "docBase" and "path". I believe they are illegal in a
context.xml file, since the server has already determined where your
application is and to what URL it will be deployed. It is rumored to be
"bad" to set these attributes in context.xml. It might even cause Tomcat
to double-deploy (or worse, double-deploy on top of each other) your
webapp and cause great confusion.

>       <Resource name ="jdbc/usermgr" auth="Container" 
> type="javax.sql.DataSource"
>       driverClassName="org.postgresql.Driver" 
> url="jdbc:postgresql://127.0.0.1:5432/users"
>       username="tomcat" password="x"
>       maxActive="20" maxIdle="10" maxWait="-1" />
> </Context>

The rest of this looks good, and matches the configuration I use for my
webapps.

> Cause: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC 
> driver of class '' for connect URL 'null'

Yup, this is going to be a subtle configuration error. Make the changes
I suggested above and see if that helps. If not, do a quick search in
the archives for "cannot create jdbc driver null": this question comes
up occasionally.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFyOGJ9CaO5/Lv0PARAploAJ4iTOetTTXFx1Vm1u7qH6JoZGlypACfYB34
X5BU6cSfeJxgEj3pIKFf7Ts=
=t4Qy
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to