Rob Tanner wrote:
I meant WAR file not JAR. As far as server.xml, how else does one specify the specifics, such as the path variable?

Here are the two application contexts:

        <Context crossContext="true" debug="0"
            docBase="AccountManager"
            path="/accntManager" reloadable="true">
          <Logger className="org.apache.catalina.logger.FileLogger"
                     prefix="localhost_accntmanager_log." suffix=".txt"
              timestamp="true"/>
         </Context>

        <Context crossContext="true" debug="0"
            docBase="GroupAliases"
            path="/mailtools/aliases" reloadable="true">
          <Logger className="org.apache.catalina.logger.FileLogger"
                     prefix="localhost_aliases_log." suffix=".txt"
              timestamp="true"/>
        </Context>

... and so the klaxons sound once again.

I'll try to beat Chuck's standard rapid fire response to this question.

Recent versions of Tomcat recommend that the Context is defined in a separate file in one of a couple of locations. Read the docs at tomcat.apache.org for more detailed info.

If you're deploying via a WAR file you can put a context.xml file in META-INF, which will produce the effect you're looking for.

The context path is determined by the name of the WAR, and not the path attribute of the Context, (which is deprecated and only acknowledged when defining a Context in server.xml - seriously discouraged these days).

(N.B. There's no Logger element any more either, see the docs.)

p



The AccountManager app works fine, but the "GroupAliases" generates this error:

May 16, 2007 3:04:06 PM org.apache.catalina.core.ApplicationContext log
INFO: Marking servlet GroupAliasManager as unavailable
May 16, 2007 3:04:06 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Allocate exception for servlet GroupAliasManager
javax.servlet.ServletException: Error instantiating servlet class 
GroupAliasManager
        at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1127)
        at 
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
        at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
        at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
        at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
        at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
        at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
        at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
        at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
        at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
        at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
        at 
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
        at java.lang.Thread.run(Thread.java:619)



-- Rob


Caldarale, Charles R said the following on 05/16/2007 02:32 PM:
From: Rob Tanner [mailto:[EMAIL PROTECTED] Subject: Problem deploying existing webapp in new Tomcat container

I installed Sun Java jdk1.6.0 and apache-tomcat-6.0.13. I copied over
the server.xml config for the first web aplication as well as the JAR
file and everything worked fine.

That sounds a bit scary, since webapps are not supposed to be configured
in server.xml anymore, and they should be packaged in .war files, not
JARs.  You need to at least post your config, since that's likely where
the problem is.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to