Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Exception using tiles for declarative exceltion handling in Struts

Status
Not open for further replies.

bcnichols

Programmer
May 31, 2005
1
US
Hello I am trying to use a tiles definition for my error page in Struts and I keep getting a problem. I am using declarative exception handling and here is the relevant section of struts-config.xml

<exception key="communication.error"
type="com.klishgroup.elcanoconnector.exceptions.ServiceCommunicationException"
path="elcano.showError.page"
handler="com.klishgroup.elcanoconnector.exceptions.ElcanoExceptionHandler"/>


Here is the snippet from tiles-defs.xml

<definition name="elcano.showError.page" extends="elcano.defaultPage">
<put name="title" value="Conduit Error" />
<put name="body" value="/customer/elcano/pages/show_error.jsp" />
<put name="footer" value="elcano.showError.footer"/>
<put name="header" value="elcano.showError.header"/>
</definition>

So I am using a standard framework layout. When I use this definition in a forward from struts-config it works fine. Only when I include this as a path to an exception is there an issue. This is the exception I get in the browser

java.lang.IllegalArgumentException: Path elcanoi.showError.page does not start with a "/" character
org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1062)
org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:274)
org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:320)
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
com.interwoven.ui.base.util.SetRequestEncodingFilter.doFilter(SetRequestEncodingFilter.java:105)



I have tried to look around and see if there is a known issue with using a tiles definition for a target path for exceptions and haven't seen anything explicit.

Any ideas what else could be at issue here?

Thanks,

BN
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top