Edit Edit

Java Servlet FAQ

How do you debug a servlet?

1) Dump debug information to the Web server's log file with the log() method:

public void log (String msg)

Also, if your servlet throws an exception, your Web server may automatically log the exception.

2) Use a debugger. Most debuggers allow you to debug a servlet but you need to do some extra setup work because the servlet is not a standalone program. In general, you'll need to

Check your debugger's documentation for more specific instructions on how to debug servlets.

Last updated 12/26/1999 04:38:20 PM