• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

where to lookout for console messages while working in notepad?

 
pras
Ranch Hand
Posts: 188
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have written the following program which basically demonstrates Servelt life cycle.

i worked it in a notepad.


now where do i look for console messages??
[ June 15, 2008: Message edited by: Bear Bibeault ]
 
pras
Ranch Hand
Posts: 188
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
public class LifeCycle extends HttpServlet {

public static int instanceCount;
{
System.out.println("Doing static initialization on LifeCycle class");
instanceCount = 0;

}

public void init() {
System.out.println("In init() on LifeCycle");
}

public LifeCycle() {
instanceCount++;
System.out.println("In LifeCycle constructor");
}

public void destroy() {
System.out.println("In destroy() on LifeCycle");
}

public void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
System.out.println("In doGet() on LifeCycle");
try {
throw new Exception();
} catch (Exception e) {
// Just doing this to show doGet() called from service()
e.printStackTrace();
}
}

}
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64620
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The fact that you used Notepad to write the code is pretty much moot. What matters is what servlet container you are using to deploy the web app and how it is configured.
 
pras
Ranch Hand
Posts: 188
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi ,

i used tomcat 5.5 version server.


guys i got the information that it is found in logs file in tomcat directory.


thanks for the quick response
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic