[ https://issues.apache.org/jira/browse/CAMEL-4058?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13044933#comment-13044933 ]
Claus Ibsen commented on CAMEL-4058: ------------------------------------ Been looking into this a bit more. I think we should keep current behavior as fix that broken issue from CAMEL-3989 where onException(MyException.class).handled(false) will cause the DLC to kick in, which was not the intention. Then we don't need this overlay stuff. It also just introduces to many variables, as you would need to test with 2x for each overlay option. > OnException should overlay settings with existing error handler > --------------------------------------------------------------- > > Key: CAMEL-4058 > URL: https://issues.apache.org/jira/browse/CAMEL-4058 > Project: Camel > Issue Type: Bug > Components: camel-core > Affects Versions: 2.7.2 > Reporter: Claus Ibsen > Assignee: Claus Ibsen > Fix For: 2.8.0 > > > See CAMEL-3989 > When you have an OnException it should overlay its configuration with the > existing error handler (so its kinda of merge). However we mistakenly set the > handled policy from the OnException always, and dont honor the setting from > the error handler. So in case of DeadLetterChannel which always handle the > exception, it will cause the exception to not be handled and thus rethrown in > Camel. > This problem is only apparent when using the DLC as its the only error > handler that handles and moves the exchange to the DLC. The other error > handler will log or the likes, but still keep the exception on the exchange > to propagated back the exception to the caller. > So we only noticed this when testing with DLC, and what Hadrian was trying to > do in CAMEL-3989 -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira