> From: Lev A KARATUN [mailto:[email protected]]
> Subject: RE: How can I access tomcat's logs using my jsp?
> when I'm copypasting the default servlet block to
> $CATALINA_BASE/logs/WEB-INF/web.xml, the application
> no longer works.
There's an additional step required for Tomcat 6 that's not necessary for
Tomcat 7. So either upgrade, or do the following:
Change the name of the DefaultServlet in logs/WEB-INF/web.xml to logsdefault
(or some other unique label):
<servlet-name>logsdefault</servlet-name>
and add a <servlet-mapping> for it:
<servlet-mapping>
<servlet-name>logsdefault</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping>
Tomcat 6 does not allow you to override the <servlet-name> settings in the
global conf/web.xml, but Tomcat 7 does.
> And one more question - if myapp's docBase is set to $CATALINA_BASE/logs ,
> does it matter what is in the webapps/myapp folder?
Assuming the "myapp" you're referring to is the one for accessing Tomcat's
logs, you should not risk problems by also having a webapps/myapp. It
shouldn't hurt, but...
And, as usual, ignore Martin G's irrelevant ramblings.
- 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 unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]