Handled Exception in Recipient List sub-route

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Handled Exception in Recipient List sub-route

DariusX
I use RecipientList with a custom Aggregator. If there is an error in a
sub-route (one of the "recipients") that is "handled" there.
I want the main route to continue
In the Aggregator, I was setting:
    if (oldExchange == null) {
        oldExchange = newExchange;
   }

Because of this, the Exchange had properties like "CamelExceptionCaught"
and "CamelErrorHandlerHandled"
And, because these were present in the Aggregated Exchange the flow was
not continuing through the outer route

After removing these two, the flow continued through the main route

I have two questions about this:
1. Does this sound like the right way to handle things in the Aggregator?
2. Any other Properties that I need to watch out for an remove, if present?


---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus