cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Melhem <>
Subject [PROPOSAL] Extending Sitemap Error Handling
Date Wed, 10 Jul 2002 11:24:40 GMT
Dear Cocoon community,

It seems to me that pipelines can only handle two error cases: Namely error 500 (General Exception)
and error 404 (ResourceNotFoundException).

There appears to be no way currently to handle specific errors that might be thrown by pipeline
components other than to render a general Error 500 page. Am I mistaken?

For example, it may be the case that a custom built generator could throw custom Exceptions
that a developer would like to handle in a specific fashion.

To that end, I propose that pipeline be extendend so that it they can handle X number of errors
depending on the amount of <map:handle-errors> defined in the sitemap for that pipeline.


  <map:handle-errors type="500">
    <map:transform src="stylesheets/error2html.xsl"/>

   <map:handle-errors type="404">
    <map:transform src="stylesheets/error2html.xsl"/>
    <map:serialize />

   <!-- one more or extra error-handles -->
   <map:handle-errors type="someSpecificException">
    <-- "type" here could me some sort of short code or the actual
        full name of the Exception class? -->
    <map:transform src="stylesheets/SpecificError2html.xsl"/>
    <map:serialize status-code="500"/>


Does anyone see any problems with this approach? Comments?

Best Regards,
Michael Melhem

To unsubscribe, e-mail:
For additional commands, email:

View raw message