camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sven Bauhan <sven.bau...@ast.dfs.de>
Subject How to catch a DirectConsumerNotAvailableException?
Date Tue, 13 May 2014 18:20:23 GMT
Hi,

I have a route with a direct endpoint going to a socket connection. It 
can be the the program on the other side of the connection crashes and 
the connection is shut down. My messages in the route cannot be 
delivered any more. This happens especially from the aggregator in the 
route.

In the log file I can see that for each aggregated message a 
DirectConsumerNotAvailableException is thrown. Now I want to catch this 
exception to advise the Aggregator  to report an error to the sender of 
the message instead of a success message.

Do I have to catch the exception on the route or in the aggregator? How 
can I handle it in the Aggregator::onCompletion() method?

Thanks,
Sven


Mime
View raw message