You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2019/04/18 07:57:00 UTC

[jira] [Commented] (CAMEL-13431) Intercept doesn't work when onException's maximumRedeliveries is set

    [ https://issues.apache.org/jira/browse/CAMEL-13431?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16820816#comment-16820816 ] 

Claus Ibsen commented on CAMEL-13431:
-------------------------------------

Can you try with a newer/latest version

> Intercept doesn't work when onException's maximumRedeliveries is set
> --------------------------------------------------------------------
>
>                 Key: CAMEL-13431
>                 URL: https://issues.apache.org/jira/browse/CAMEL-13431
>             Project: Camel
>          Issue Type: Bug
>          Components: came-core
>    Affects Versions: 2.21.2
>            Reporter: Vladimir Bogatyrov
>            Priority: Major
>
> When both intercept() and onException() are applied to the route and maximumRedeliveries() is set, then interceptor is not called. If maximumRedelvieries() is removed, interceptor works. Here is an example:
> {code:java}
> public class MyRouteBuilder extends RouteBuilder {
>     public void configure() {
>         intercept()
>                 .setBody().constant("Intercepted-message");
>         onException()
>                 .maximumRedeliveries(2) // comment this line to make intercept() work
>                 .log("${body}");
>         from("timer:mytimer?repeatCount=1&delay=1000")
>                 .setBody().constant("Hello Test")
>                 .log("${body}");
>     }
> }
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)