camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ychawla <premiergenerat...@yahoo.com>
Subject Re: not getting exception from exchange
Date Wed, 10 Dec 2008 18:20:40 GMT

Sorry,
Let me clarify.  The technique below works fine if you go directly to a
bean, but if there is a queue in the middle then you lose the exception. 
The test I ran was incorrect.  
-Yogesh


ychawla wrote:
> 
> Hi Claus,
> Thanks for the response.  Since I have camel on both ends of the queue
> here, it is easy enough to set a message property to handle it:
> 
> Throw an exception like this:
> Exception exception = new Exception("No Client ID was found.");
> exchange.getIn().setHeader("SSAFException", exception);
> throw exception;                 
> 
> Have a bean in a pipeline for my error queue and get the Exception:
> Exception ssafException = (Exception) message.getHeader("SSAFException");
> 
> I see some of the design challenges of preserving exceptions over JMS
> especially when you don't want consumer is on the other end.  For my issue
> it is camel to camel in the same JVM so this works great.
> 
> I am going to review the JIRA's and throw in a vote.
> 
> Cheers,
> Yogesh
> 

-- 
View this message in context: http://www.nabble.com/not-getting-exception-from-exchange-tp20926633s22882p20940978.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Mime
View raw message