You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Donald Ball <ba...@webslingerZ.com> on 2001/06/25 19:56:00 UTC
how to indicate fatal exception in a transformer?
how do i indicate that a fatal exception has occured in a transformer,
specifically, in one of the SAX event handler methods? i would think that
i'd throw a ProcessingException, but that's not allowed per the method
signature of XMLProducer interface. when i throw a SAXException, i don't
end up with an internal server error being tossed to the client, the
request just hangs. what's the best practice for this situation?
- donald
---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org
Re: how to indicate fatal exception in a transformer?
Posted by Donald Ball <ba...@webslingerZ.com>.
On Mon, 25 Jun 2001, giacomo wrote:
> > how do i indicate that a fatal exception has occured in a transformer,
> > specifically, in one of the SAX event handler methods? i would think that
> > i'd throw a ProcessingException, but that's not allowed per the method
> > signature of XMLProducer interface. when i throw a SAXException, i don't
> > end up with an internal server error being tossed to the client, the
> > request just hangs. what's the best practice for this situation?
>
> Yes, the Exception handling of C2 isn't complete. Have you tried the
> Avalon CascadingRuntimeException?
no, sure haven't. will it divert the pipeline to the error section? based
on what i've seen, only ProcessingExceptions will do that, but i could
easily be wrong.
just as a general suggestion - a little HOWTO on writing cocoon components
would be a grand thing to add to the docs. what interfaces you should
implement (and when and why), what exceptions you should toss (and when
and why), etc.
- donald
---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org
Re: how to indicate fatal exception in a transformer?
Posted by giacomo <gi...@apache.org>.
On Mon, 25 Jun 2001, Donald Ball wrote:
> how do i indicate that a fatal exception has occured in a transformer,
> specifically, in one of the SAX event handler methods? i would think that
> i'd throw a ProcessingException, but that's not allowed per the method
> signature of XMLProducer interface. when i throw a SAXException, i don't
> end up with an internal server error being tossed to the client, the
> request just hangs. what's the best practice for this situation?
Yes, the Exception handling of C2 isn't complete. Have you tried the
Avalon CascadingRuntimeException?
Giacomo
---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org