This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

debugging a servlet  RSS feed

 
mustang india
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I would like to know what is the elegant way to debug a srvlet deployed in an app server. I have been doing using System.out.println() statements. But this seems to be "not so good" way of debugging.
Regards,
Mustang.
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can download the debugging chapter from my Servlets and JSP book from:
http://www.lanw.com/books/servletjsp/default.htm
Debugging servlets is tricky because there are so many places to go wrong.
Bill
 
Michael OBrien
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I use the javix debugger because it is lite. www.javix.com.
In weblogic, you start the vm that launches weblogic server with the appropriate debug command line switches. Then, you use the debugger to connect to a remote process.
It works great. I can break in my controller servlet (struts) and step through code. You compile your classes with -g so all debug info is present.
 
Adam Hardy
Ranch Hand
Posts: 567
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
or there's Jakarta log4j or the new logging that comes with J2SE 1.4
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!