I'm not sure if you are using consumer.exceptionHandler[1] to do this kind of 
job.
There are some enhancement since Camel 2.10.0, you can define a 
consumer.bridgeErrorHandler[2] to catch the exception if it is thrown from the 
file of ftp consumer.

[1]http://camel.apache.org/file2.html#File2-HowtousetheCamelerrorhandlertodealwithexceptionstriggeredoutsidetheroutingengine

[2]http://camel.apache.org/file2.html#File2-Usingconsumer.bridgeErrorHandler 

-- 
Willem Jiang

FuseSource
Web: http://www.fusesource.com (http://www.fusesource.com/)
Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) 
(English)
          http://jnn.javaeye.com (http://jnn.javaeye.com/) (Chinese)
Twitter: willemjiang 
Weibo: willemjiang





On Wednesday, September 5, 2012 at 12:56 PM, vishal1981 wrote:

> Hi,
> I am implementing the ExceptionHandler to catch exceptions that happen while
> fetching a file remotely via FTP (e.g. IOExceptions etc.).
> In my custom ExceptionHandler I need a way to figure out which endpoint/FTP
> URI failed since I have more than one.
> The ExceptionHandler method -handleException which gets invoked only gets
> the exception and not the originating FTP endpoint. How can I possibly find
> that out. I have an exchange header but I guess the exchange is not even
> constructed if the first endpoint fails.
> The Exception handler is an Stateless session bean and will be shared across
> several routes.
> 
> I am using 2.9 release. 
> Thanks in advace,
> -v-
> 
> 
> 
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/Getting-consumer-endpoint-details-or-exchange-headers-in-custom-ExceptionHandler-tp5718633.html
> Sent from the Camel - Users mailing list archive at Nabble.com 
> (http://Nabble.com).



Reply via email to