Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Configuring RunTimeException class in Struts2

 
James Peter
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

My requirement is as follows. My application is built on Struts2 framework and using annotation plugin. When I get any RunTimeException I need to call a method of my custom class which prints error stack using e.printStackTrace() method. How can I configure this class in my application. I do not want to use try and catch block in each and every actions I have.

After getting error I want to display error.jsp to user. but in my tomcat console I would like to print error stack. Please let me know if anyone is having idea.

Thanks
Peter
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic