Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to configure custom error pages in jboss-5.1.0?

 
Skanda Raman
Ranch Hand
Posts: 205
Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

My query is how to configure custom error pages in jboss 5.1.0

Previously i was using jboss 4.0.0 and hence to display custom error pages I followed the below steps.

1. Added following xml tags in jboss-4.0.0/server/default/deploy/jbossweb-tomcat50.sar/web.xml



2. Placed pagenotfound.jsp and servererror.jsp in jboss-4.0.0/server/default/ deploy/jbossweb-tomcat50.sar/ROOT.war folder.

Currently I started using jboss 5.1.0 but couldn't find jbossweb-tomcat50.sar folder. When i navigated into \jboss-5.1.0\server\default\deploy\jbossweb.sar i couldn't find web.xml or ROOT.war folder. So i tried creating missing folders and files but of couldn't solve the problem.

Please let me know how to configure custom error pages in jboss 5.1.0
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In 5.0.x and 5.1.0, the global web.xml file is located at server/xxx/deployers/jbossweb.deployer/web.xml, and ROOT.war is at server/xxx/deploy/ROOT.war
 
JL Smith
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Could anyone shine a little more light on _exactly_ how to setup custom error pages in jboss-5.1.0? I've googled and googled but I can't find a solution that works. I even looked through JBoss in Action and couldn't find anything on the subject. Thanks for any help.
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Customer error pages are really a JSP/servlet feature, not anything specific to JBoss AS. What books/articles have you looked at on this topic? (Try this http://pdf.moreservlets.com/ - chapter 5.) What have you done so far that has not worked?
 
JL Smith
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the suggestions Peter. Custom error pages have nothing to do with JBoss. My web.xml was using an older dtd spec and it wasn't able to parse the <error-page> that I had added...that's why I thought it was a JBoss problem. All is good after correcting my web.xml. Thanks.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic