Oh, Thanks a lot, I would have never guessed that it is a bug in tomcat. But I would like to ask a follow up question.
If I change the testprojekt.xml in conf/Catalina/localhost/testprojekt.xml my webapplication will be redeployed (assuming the bug is fixed), and it would get the new values. If I change the conf/context.xml all my webapps will be RELOADED, but new values and changes to values in conf/context.xml will not be given to the webapp. I am using the tomcat connection pooling to connect to a postgres DB, I would like to put the configuration (hostname, username, etc) somewhere, so that i can change it, when I change the databasehost. Where is the right place to put such a configuration? If i put the configuration in conf/context.xml the changes to the values wont be given to running applications. If i put it in the conf/Catalina/.... the application will be redeployed, which causes downtimes. What is the right place to PUT and later change the connection infos to the database? Thank you again for your help. Regards, Carsten Pohl ----- Original Message ----- From: "Markus Schönhaber" <tomcat-us...@list-post.mks-mail.de> To: users@tomcat.apache.org Sent: Monday, 2 November, 2009 13:53:15 GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna Subject: Re: Understanding context.xml Carsten Pohl: > When I deploy the project to a local tomcat (Apache Tomcat/6.0.20) Everything > works as expected. Meaning, the context.xml is copied to > /conf/Catalina/localhost and renamed to testprojekt.xml. > > When I edit the testprojekt.xml to: > > <?xml version="1.0" encoding="UTF-8"?> > <Context> > <Parameter name="companyName" value="My BLAH Company, Incorporated" > override="false"/> > </Context> > > I see the following output in the catalina.out: > > 02.11.2009 13:21:35 org.apache.catalina.startup.HostConfig checkResources > INFO: Undeploying context [/testprojekt] > 02.11.2009 13:21:35 org.apache.catalina.core.StandardContext resourcesStart > SCHWERWIEGEND: Error starting static Resources > java.lang.IllegalArgumentException: Document base > /opt/tomcat6/webapps/testprojekt does not exist or is not a readable directory [...] > INFO: Container > org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/testprojekt] > has not been started > > Why is that? Is that the expected result? What is the right way to change > parameters in a context.xml? You might be affected by this bug: https://issues.apache.org/bugzilla/show_bug.cgi?id=47343 -- Regards mks --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org