You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Cliff Willsher <cl...@iabatab.com> on 2003/11/14 08:31:52 UTC

DBCP and reloading war file

Hi,

I have configured my server and web-app to use a DBCP datasource. All works 
well after the server has been started. If I then replace the war file with 
an updated version, the server notices the change and redeploys the war 
file and loads the updated application, however the JNDI datasource now 
fails. A datasource is returned from the lookup but the driver name 
attribute is null hence the consequent access fails.

Restarting the server make things work normally again.

I am using Tomcat 5.0.14 with Java SDK 1.4.2_02 with MySQL connector 
version 3.0.9

I believe I have eliminated any application errors by going back to the 
example from the Tomcat docs and this displays the same behaviour so I 
guess I have something configured badly. I will post all the configuration 
info if needed.

Any help appreciated.

Cliff


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


RE: DBCP and reloading war file

Posted by "Brent@VendorSolutions.com" <br...@vendorsolutions.com>.
Hey Cliff,

I have a similar problem with Tomcat 4.1., but I am using the same
connector and the same SDK as you.  

I am not sure if I can help, because I have not yet solved it on my end.
However, I have been trying to work with the catalina.policy file to
grant rights to Tomcat to startup the MySQL connection.  

grant codeBase "file:/usr/local/mysql/-" {
  permission java.security.AllPermission;
};

// Connect to MySQL
permission java.net.SocketPermission "localhost:3306",
"read,connect,resolve,listen";

permission java.util.PropertyPermission "file.encoding", "read";


I have been trying the above modifications to the catalina.policy file,
but is not working.  Please reply to the group when you solve in ( and I
am using 4.1 not 5.0 )

Brent 


-----Original Message-----
From: Cliff Willsher [mailto:cliff@iabatab.com] 
Sent: Thursday, November 13, 2003 11:32 PM
To: tomcat-user@jakarta.apache.org
Subject: DBCP and reloading war file


Hi,

I have configured my server and web-app to use a DBCP datasource. All
works 
well after the server has been started. If I then replace the war file
with 
an updated version, the server notices the change and redeploys the war 
file and loads the updated application, however the JNDI datasource now 
fails. A datasource is returned from the lookup but the driver name 
attribute is null hence the consequent access fails.

Restarting the server make things work normally again.

I am using Tomcat 5.0.14 with Java SDK 1.4.2_02 with MySQL connector 
version 3.0.9

I believe I have eliminated any application errors by going back to the 
example from the Tomcat docs and this displays the same behaviour so I 
guess I have something configured badly. I will post all the
configuration 
info if needed.

Any help appreciated.

Cliff


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



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