You want to configure the WTP environment, the following JNDI, there are two ways, one is in the Server project server.xml in the preparation of jndi the xml tags, but if you do not want to do this, but would like to "conf \ Catalina \ localhost" the following new xml should be a how to do it directly in wtp release directory "conf \ Catalina \ localhost" in the new name of a project. xml does not work, because every time the server starts the file will be overwritten. Can then project WebRoot / META-INF folder, create a new one the following context.xml, your context configuration and jndi configuration written in this file inside, and then open the server configuration interface, check the "publish module context to separate XML file" you're done. Start the server, the contents of the context.xml will be copied to the "conf \ Catalina \ localhost" in the.
How do I specify the Tomcat context configuration for my Web Application?
The configuration within <Context> elements may be added to the server.xml file associated with the Tomcat server, after the project has been added to the server. Note that if the project is removed from the server, this configuration will be lost. You can save a copy of the configuration in some file in your project if you want to persist this information.
Another approach is use the support found in Tomcat 4.1 and later for specifying context configuration within a META-INF/context.xml file found in the Web application. If a project containing a META-INF/context.xml file is added to one of these Tomcat servers in WTP, the context configuration found in this file will be included in the context for that project when server.xml, or separate context XML file in WTP 2.0.x and later, is file copied as part of publishing the server. When adding the configuration from the META-INF/context.xml file, all child elements of the <Context> are copied as well as its attributes, excluding the "path" and "docBase" attributes.