tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jim Carlson <>
Subject WAR format question
Date Mon, 03 Feb 2003 21:42:52 GMT
   I have a question about the WAR directory structure.  Namely, where 
is the appropriate place to put configuration files, log files, and 
other files that need to be read/written-to by my application?  Clearly 
putting them in the webroot isn't right.  Can my application access 
arbitrary files under WEB-INF?  How?  I know that conf files can be put 
in the classpath (e.g. WEB-INF/classes), but this seems like the wrong 
solution for files that will change after deployment.
   In the past, I've used the technique of creating my own application 
root, which contained a webroot/ directory in the WAR format, and 
pointed the servlet container at that.  I used servlet parameters in the 
web.xml file to specify the location of the application root to my 
servlets, so that they could access my conf/log files.  This works fine, 
but forces me to 'embrace and extend' the orginal WAR concept.
   Any suggestions?


Jim Carlson

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

View raw message