Chapter 5: Basic Tomcat Confi guration Subelement Description How Many? DefaultContext Realm The configures the set of property values for a Web application that is deployed within this host but that does not have its own specified. Typically, this is used by Web applications that are automatically deployed. A Realm that can be accessed across all the Web applications running within this host, unless a lower-level component specifies its own Realm. 0 or 1 0 or 1 Web Application Context Definitions In Tomcat 6, administrator-controlled application Context Descriptor XML files are placed in the $CATALINA_HOME/conf// directory. This is done to maximize the decoupling between server and application configuration, and to improve deployment security. Web application specific Context descriptors can be embedded in the WAR file, under META-INF/ context.xml, and included with the Web application being deployed. Administrators can, at their discretion, disable the parsing of these embedded context.xml files on a per-host basis via the deployXML attribute of the host, documented earlier. This concludes the examination of the default server.xml file. The remainder of the chapter examines the other configuration files found in the $CATALINA_HOME/confdirectory. The Default context.xml File The context.xmlin the $CATALINA_HOME/conf directory is the default Context descriptor loaded with every single application running on the Tomcat instance. Because of the global nature of this default Context, it should contain only configuration entries that you need to apply across all Web applications and across all virtual hosts. (The nested component has the same effect, but across all Web applications in a single host.) This default context.xml contains only one line (all comments are removed in the following listing): WEB-INF/web.xml The web.xmlspecified in the nested component is watched by the Context s background processing for changes. Whenever this resource is changed, the application is redeployed by the Tomcat autodeployer (unless this feature is disabled explicitly). A element is a container. It can have any one of the attributes shown in the following table.
If you looking for unlimited one inclusive web hosting plan please check web hosting plan website.
This entry was posted
on Wednesday, February 18th, 2009 at 12:18 pm and is filed under tomcat.
You can follow any responses to this entry through the RSS 2.0 feed.
Responses are currently closed, but you can trackback from your own site.