tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bo Xu ...@cybershop.ca>
Subject Re: log() ?
Date Tue, 27 Feb 2001 21:52:13 GMT
Shahed Ali wrote:

> Sorry for this stupid question,
> but how do I use the log() method in servlets ?
>
> In JSP application.log() seems to work,
> but in servlets, I tried getServletContext().log("adad") etc and
> I keep getting NullPointerExceptions
>
> Thanks
> Shahed
> [...]

Hi :-)  I also have this question:
*   I put "this.getServletContext().log("aaaaa");" in "service(...)"
      method in MyServlet
*   in TOMCAT_HOME/logs, I find several kinds of log files:
     - localhost_log.2001-02-27.txt
     - localhost_examples_log.2001-02-27.txt
     - catalina_log.2001-02-27.txt
     - catalina.out
     - localhost_access_log..txt

     every time when I access MyServlet, I find Only
      localhost_access_log..txt is updated, but I didn't
      find "aaaaa" in it.  could anybody tell me how to
      do it?


Thanks in advance!

Bo
Feb.27, 2001




Mime
View raw message