I am trying to migrate my application from Resin to Tomcat 6.0.18. The
application runs fine, but my application context name(the context is
created) is coming as null in Tomcat. I tried using context.xml but still I
am facing the same problem.

In Resin the equivalent configuration in resin.conf looks like this

<web-app id="/Foo" root-directory="webapps/Foo"/>

Can someone please let me know as to what exactly should I put in
context.xml, where should I place it in Tomcat and should it be called
context.xml or should it be renamed to my web application name?

I tried with the following:

Content of xml file(WAR file is foo.war under webapps folder):

<Context docBase="Foo" >
    <WatchedResource>WEB-INF/web.xml</WatchedResource>
</Context>

Renamed the file from context.xml to foo.xml.

Placed it in the default conf folder as well as
conf/Catalina/localhost/foo.xml and conf/Catalina/localhost/context.xml

Placed both context.xml as well as foo.xml in my web application META-INF
folder.

None of the above worked.

Also is the context.xml or <webappName>.xml automcatically picked or should
server.xml be informed of this file?
-- 
Cheers,
Abhi

Reply via email to