Hi, >Let's say that I don't want to mess with my working server.xml. If I >have an application that's accessed via "webapps/myapp/jsp/index.html", >where would I put the RemoteAddrValve code? Do I create a context >fragment called webapps/myapp.xml and put it there? I'd rather not have >to add a context declaration for every application into the server.xml. >I have quite a few applications, and they all have different access >requirements.
You can put the Valve in the myapp.xml file if you'd like. You can put myapp.xml in the webapps directory, in the $CATALINA_HOME/conf/[engine]/[host] directory, or in the app's WAR file's META-INF directory. This is all explained in detail in the tomcat configuration reference documentation: start with the Host configuration page and follow the link to the document titled "Automatic Application Deployment." Of course, having a separate myapp.xml file for each webapp is just as much work as having an entry for each in server.xml: both approaches have pros and cons, but they're the essentially the same amount of work ;) Don't be afraid of modifying server.xml: make a backup copy, make your changes, try them out, and you can always go back to the working one. Yoav This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]