Infinite recursion of exceptions. Is it a bug?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
18 messages Options
Reply | Threaded
Open this post in threaded view
|

Infinite recursion of exceptions. Is it a bug?

Christian Schneider
I have the routes below. When I send a message to direct:test I get an
infinite recursion of exceptions.
The reason is that the onException handler also seems to be called for
the direct:handle_er that is called when handling the
first exception. In case such a handler route also throws an exception
the recursion happens.

Is this expected or a bug?
If it is not a bug what do we recommend our users to avoid the recursion?

                 onException(Throwable.class)
                 .to("direct:handle_er");

                 from("direct:test")
                 .throwException(new RuntimeException())
                 .to("log:test2");

                 from("direct:handle_er")
                 .throwException(new RuntimeException());

See also https://issues.apache.org/jira/browse/CAMEL-11229

Christian

--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

arnaudeprez
Hi Christian,

I think it's expected as you use a global onException handler.

So to not have the recursion problem, you should do something like:

 from("direct:test")
    .onException(Throwable.class)
        .to("direct:handle_er")
        .end()
    .throwException(new RuntimeException())
    .to("log:test2");

from("direct:handle_er")
     .throwException(new RuntimeException());


On Thu, May 4, 2017 at 5:30 PM Christian Schneider <[hidden email]>
wrote:

> I have the routes below. When I send a message to direct:test I get an
> infinite recursion of exceptions.
> The reason is that the onException handler also seems to be called for
> the direct:handle_er that is called when handling the
> first exception. In case such a handler route also throws an exception
> the recursion happens.
>
> Is this expected or a bug?
> If it is not a bug what do we recommend our users to avoid the recursion?
>
>                  onException(Throwable.class)
>                  .to("direct:handle_er");
>
>                  from("direct:test")
>                  .throwException(new RuntimeException())
>                  .to("log:test2");
>
>                  from("direct:handle_er")
>                  .throwException(new RuntimeException());
>
> See also https://issues.apache.org/jira/browse/CAMEL-11229
>
> Christian
>
> --
> Christian Schneider
> http://www.liquid-reality.de
>
> Open Source Architect
> http://www.talend.com
>
> --
Arnaud Deprez
Software Engineer
Phone: +32 497 23 30 44
Linked'In: https://www.linkedin.com/in/deprezarnaud
Github: https://github.com/arnaud-deprez
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Christian Schneider
So the best recommendation is to not use a global onException handler?

Christian

On 04.05.2017 17:52, Arnaud Deprez wrote:

> Hi Christian,
>
> I think it's expected as you use a global onException handler.
>
> So to not have the recursion problem, you should do something like:
>
>   from("direct:test")
>      .onException(Throwable.class)
>          .to("direct:handle_er")
>          .end()
>      .throwException(new RuntimeException())
>      .to("log:test2");
>
> from("direct:handle_er")
>       .throwException(new RuntimeException());
>
>
> On Thu, May 4, 2017 at 5:30 PM Christian Schneider <[hidden email]>
> wrote:
>
>> I have the routes below. When I send a message to direct:test I get an
>> infinite recursion of exceptions.
>> The reason is that the onException handler also seems to be called for
>> the direct:handle_er that is called when handling the
>> first exception. In case such a handler route also throws an exception
>> the recursion happens.
>>
>> Is this expected or a bug?
>> If it is not a bug what do we recommend our users to avoid the recursion?
>>
>>                   onException(Throwable.class)
>>                   .to("direct:handle_er");
>>
>>                   from("direct:test")
>>                   .throwException(new RuntimeException())
>>                   .to("log:test2");
>>
>>                   from("direct:handle_er")
>>                   .throwException(new RuntimeException());
>>
>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>
>> Christian
>>
>> --
>> Christian Schneider
>> http://www.liquid-reality.de
>>
>> Open Source Architect
>> http://www.talend.com
>>
>> --
> Arnaud Deprez
> Software Engineer
> Phone: +32 497 23 30 44
> Linked'In: https://www.linkedin.com/in/deprezarnaud
> Github: https://github.com/arnaud-deprez
>


--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Zoran Regvart-2
Hi Christian,

On Fri, May 5, 2017 at 9:37 AM, Christian Schneider
<[hidden email]> wrote:
> So the best recommendation is to not use a global onException handler?

I think we should handle exceptions from exception handler
differently, I think we could add a flag on the exchange not to invoke
the exception handler the second time and perform default exception
handling (i.e. log the exception),

zoran
--
Zoran Regvart
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Christian Schneider
Sounds good to me. I can work on that if we agree in this concept.

Christian

On 05.05.2017 10:51, Zoran Regvart wrote:

> Hi Christian,
>
> On Fri, May 5, 2017 at 9:37 AM, Christian Schneider
> <[hidden email]> wrote:
>> So the best recommendation is to not use a global onException handler?
> I think we should handle exceptions from exception handler
> differently, I think we could add a flag on the exchange not to invoke
> the exception handler the second time and perform default exception
> handling (i.e. log the exception),
>
> zoran


--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

dkulp@apache.org
In reply to this post by Zoran Regvart-2

Agreed:  one thing though… there are two exceptions at that point.  The original exception and the exception from the exception handler.   I would say both exceptions should be logged.   The original exception is obviously important, but the other exception is likely needed to diagnose why the exception handler is failing.

Dan


> On May 5, 2017, at 4:51 AM, Zoran Regvart <[hidden email]> wrote:
>
> Hi Christian,
>
> On Fri, May 5, 2017 at 9:37 AM, Christian Schneider
> <[hidden email]> wrote:
>> So the best recommendation is to not use a global onException handler?
>
> I think we should handle exceptions from exception handler
> differently, I think we could add a flag on the exchange not to invoke
> the exception handler the second time and perform default exception
> handling (i.e. log the exception),
>
> zoran
> --
> Zoran Regvart

--
Daniel Kulp
[hidden email] - http://dankulp.com/blog
Talend Community Coder - http://coders.talend.com

Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Christian Schneider
In reply to this post by Christian Schneider
I have pushed a test and a possible fix to
https://github.com/apache/camel/tree/CAMEL-11229

As the code around error handling is pretty difficult to understand I am
not sure if my solution is good. I would be happy if someone could
review my change.

Christian

On 04.05.2017 17:30, Christian Schneider wrote:

> I have the routes below. When I send a message to direct:test I get an
> infinite recursion of exceptions.
> The reason is that the onException handler also seems to be called for
> the direct:handle_er that is called when handling the
> first exception. In case such a handler route also throws an exception
> the recursion happens.
>
> Is this expected or a bug?
> If it is not a bug what do we recommend our users to avoid the recursion?
>
>                 onException(Throwable.class)
>                 .to("direct:handle_er");
>
>                 from("direct:test")
>                 .throwException(new RuntimeException())
>                 .to("log:test2");
>
>                 from("direct:handle_er")
>                 .throwException(new RuntimeException());
>
> See also https://issues.apache.org/jira/browse/CAMEL-11229
>
> Christian
>


--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Zoran Regvart-2
Hi Christian,
I think that your initial example of the recursion is a simpler
example for the unit test, so with that and a minor reformat of the
source code I've committed this to my GitHub fork:

https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd

have a look, thanks :)

zoran

On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
<[hidden email]> wrote:

> I have pushed a test and a possible fix to
> https://github.com/apache/camel/tree/CAMEL-11229
>
> As the code around error handling is pretty difficult to understand I am not
> sure if my solution is good. I would be happy if someone could review my
> change.
>
> Christian
>
>
> On 04.05.2017 17:30, Christian Schneider wrote:
>>
>> I have the routes below. When I send a message to direct:test I get an
>> infinite recursion of exceptions.
>> The reason is that the onException handler also seems to be called for the
>> direct:handle_er that is called when handling the
>> first exception. In case such a handler route also throws an exception the
>> recursion happens.
>>
>> Is this expected or a bug?
>> If it is not a bug what do we recommend our users to avoid the recursion?
>>
>>                 onException(Throwable.class)
>>                 .to("direct:handle_er");
>>
>>                 from("direct:test")
>>                 .throwException(new RuntimeException())
>>                 .to("log:test2");
>>
>>                 from("direct:handle_er")
>>                 .throwException(new RuntimeException());
>>
>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>
>> Christian
>>
>
>
> --
> Christian Schneider
> http://www.liquid-reality.de
>
> Open Source Architect
> http://www.talend.com
>



--
Zoran Regvart
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Christian Schneider
Hi Zoran,

I have merged your improvements into the branch.

I will wait one more day for feedback and then merge into master.

Christian

On 08.05.2017 11:57, Zoran Regvart wrote:

> Hi Christian,
> I think that your initial example of the recursion is a simpler
> example for the unit test, so with that and a minor reformat of the
> source code I've committed this to my GitHub fork:
>
> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>
> have a look, thanks :)
>
> zoran
>
> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
> <[hidden email]> wrote:
>> I have pushed a test and a possible fix to
>> https://github.com/apache/camel/tree/CAMEL-11229
>>
>> As the code around error handling is pretty difficult to understand I am not
>> sure if my solution is good. I would be happy if someone could review my
>> change.
>>
>> Christian
>>
>>
>> On 04.05.2017 17:30, Christian Schneider wrote:
>>> I have the routes below. When I send a message to direct:test I get an
>>> infinite recursion of exceptions.
>>> The reason is that the onException handler also seems to be called for the
>>> direct:handle_er that is called when handling the
>>> first exception. In case such a handler route also throws an exception the
>>> recursion happens.
>>>
>>> Is this expected or a bug?
>>> If it is not a bug what do we recommend our users to avoid the recursion?
>>>
>>>                  onException(Throwable.class)
>>>                  .to("direct:handle_er");
>>>
>>>                  from("direct:test")
>>>                  .throwException(new RuntimeException())
>>>                  .to("log:test2");
>>>
>>>                  from("direct:handle_er")
>>>                  .throwException(new RuntimeException());
>>>
>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>
>>> Christian
>>>
>>
>> --
>> Christian Schneider
>> http://www.liquid-reality.de
>>
>> Open Source Architect
>> http://www.talend.com
>>
>
>


--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Claus Ibsen-2
On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
<[hidden email]> wrote:
> Hi Zoran,
>
> I have merged your improvements into the branch.
>
> I will wait one more day for feedback and then merge into master.
>

Can you wait some longer. Some of us have been traveling all last week
and are back in our office with jet-lag and a ton of email to catch
up.

I will take a look at this later this week.



> Christian
>
>
> On 08.05.2017 11:57, Zoran Regvart wrote:
>>
>> Hi Christian,
>> I think that your initial example of the recursion is a simpler
>> example for the unit test, so with that and a minor reformat of the
>> source code I've committed this to my GitHub fork:
>>
>>
>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>
>> have a look, thanks :)
>>
>> zoran
>>
>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>> <[hidden email]> wrote:
>>>
>>> I have pushed a test and a possible fix to
>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>
>>> As the code around error handling is pretty difficult to understand I am
>>> not
>>> sure if my solution is good. I would be happy if someone could review my
>>> change.
>>>
>>> Christian
>>>
>>>
>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>
>>>> I have the routes below. When I send a message to direct:test I get an
>>>> infinite recursion of exceptions.
>>>> The reason is that the onException handler also seems to be called for
>>>> the
>>>> direct:handle_er that is called when handling the
>>>> first exception. In case such a handler route also throws an exception
>>>> the
>>>> recursion happens.
>>>>
>>>> Is this expected or a bug?
>>>> If it is not a bug what do we recommend our users to avoid the
>>>> recursion?
>>>>
>>>>                  onException(Throwable.class)
>>>>                  .to("direct:handle_er");
>>>>
>>>>                  from("direct:test")
>>>>                  .throwException(new RuntimeException())
>>>>                  .to("log:test2");
>>>>
>>>>                  from("direct:handle_er")
>>>>                  .throwException(new RuntimeException());
>>>>
>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>
>>>> Christian
>>>>
>>>
>>> --
>>> Christian Schneider
>>> http://www.liquid-reality.de
>>>
>>> Open Source Architect
>>> http://www.talend.com
>>>
>>
>>
>
>
> --
> Christian Schneider
> http://www.liquid-reality.de
>
> Open Source Architect
> http://www.talend.com
>



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Christian Schneider
Hi Claus,

that is fine. I was hoping for you to take look.

Christian

On 08.05.2017 14:30, Claus Ibsen wrote:

> On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
> <[hidden email]> wrote:
>> Hi Zoran,
>>
>> I have merged your improvements into the branch.
>>
>> I will wait one more day for feedback and then merge into master.
>>
> Can you wait some longer. Some of us have been traveling all last week
> and are back in our office with jet-lag and a ton of email to catch
> up.
>
> I will take a look at this later this week.
>
>
>
>> Christian
>>
>>
>> On 08.05.2017 11:57, Zoran Regvart wrote:
>>> Hi Christian,
>>> I think that your initial example of the recursion is a simpler
>>> example for the unit test, so with that and a minor reformat of the
>>> source code I've committed this to my GitHub fork:
>>>
>>>
>>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>>
>>> have a look, thanks :)
>>>
>>> zoran
>>>
>>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>>> <[hidden email]> wrote:
>>>> I have pushed a test and a possible fix to
>>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>>
>>>> As the code around error handling is pretty difficult to understand I am
>>>> not
>>>> sure if my solution is good. I would be happy if someone could review my
>>>> change.
>>>>
>>>> Christian
>>>>
>>>>
>>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>> I have the routes below. When I send a message to direct:test I get an
>>>>> infinite recursion of exceptions.
>>>>> The reason is that the onException handler also seems to be called for
>>>>> the
>>>>> direct:handle_er that is called when handling the
>>>>> first exception. In case such a handler route also throws an exception
>>>>> the
>>>>> recursion happens.
>>>>>
>>>>> Is this expected or a bug?
>>>>> If it is not a bug what do we recommend our users to avoid the
>>>>> recursion?
>>>>>
>>>>>                   onException(Throwable.class)
>>>>>                   .to("direct:handle_er");
>>>>>
>>>>>                   from("direct:test")
>>>>>                   .throwException(new RuntimeException())
>>>>>                   .to("log:test2");
>>>>>
>>>>>                   from("direct:handle_er")
>>>>>                   .throwException(new RuntimeException());
>>>>>
>>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>>
>>>>> Christian
>>>>>
>>>> --
>>>> Christian Schneider
>>>> http://www.liquid-reality.de
>>>>
>>>> Open Source Architect
>>>> http://www.talend.com
>>>>
>>>
>>
>> --
>> Christian Schneider
>> http://www.liquid-reality.de
>>
>> Open Source Architect
>> http://www.talend.com
>>
>
>


--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Claus Ibsen-2
Hi

I ought to have cleared up some room for me to have time tomorrow
morning to take a look. This sort of thing requires a "calm period"
where you are not disturbed.



On Mon, May 8, 2017 at 2:37 PM, Christian Schneider
<[hidden email]> wrote:

> Hi Claus,
>
> that is fine. I was hoping for you to take look.
>
> Christian
>
>
> On 08.05.2017 14:30, Claus Ibsen wrote:
>>
>> On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
>> <[hidden email]> wrote:
>>>
>>> Hi Zoran,
>>>
>>> I have merged your improvements into the branch.
>>>
>>> I will wait one more day for feedback and then merge into master.
>>>
>> Can you wait some longer. Some of us have been traveling all last week
>> and are back in our office with jet-lag and a ton of email to catch
>> up.
>>
>> I will take a look at this later this week.
>>
>>
>>
>>> Christian
>>>
>>>
>>> On 08.05.2017 11:57, Zoran Regvart wrote:
>>>>
>>>> Hi Christian,
>>>> I think that your initial example of the recursion is a simpler
>>>> example for the unit test, so with that and a minor reformat of the
>>>> source code I've committed this to my GitHub fork:
>>>>
>>>>
>>>>
>>>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>>>
>>>> have a look, thanks :)
>>>>
>>>> zoran
>>>>
>>>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>>>> <[hidden email]> wrote:
>>>>>
>>>>> I have pushed a test and a possible fix to
>>>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>>>
>>>>> As the code around error handling is pretty difficult to understand I
>>>>> am
>>>>> not
>>>>> sure if my solution is good. I would be happy if someone could review
>>>>> my
>>>>> change.
>>>>>
>>>>> Christian
>>>>>
>>>>>
>>>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>>>
>>>>>> I have the routes below. When I send a message to direct:test I get an
>>>>>> infinite recursion of exceptions.
>>>>>> The reason is that the onException handler also seems to be called for
>>>>>> the
>>>>>> direct:handle_er that is called when handling the
>>>>>> first exception. In case such a handler route also throws an exception
>>>>>> the
>>>>>> recursion happens.
>>>>>>
>>>>>> Is this expected or a bug?
>>>>>> If it is not a bug what do we recommend our users to avoid the
>>>>>> recursion?
>>>>>>
>>>>>>                   onException(Throwable.class)
>>>>>>                   .to("direct:handle_er");
>>>>>>
>>>>>>                   from("direct:test")
>>>>>>                   .throwException(new RuntimeException())
>>>>>>                   .to("log:test2");
>>>>>>
>>>>>>                   from("direct:handle_er")
>>>>>>                   .throwException(new RuntimeException());
>>>>>>
>>>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>>>
>>>>>> Christian
>>>>>>
>>>>> --
>>>>> Christian Schneider
>>>>> http://www.liquid-reality.de
>>>>>
>>>>> Open Source Architect
>>>>> http://www.talend.com
>>>>>
>>>>
>>>
>>> --
>>> Christian Schneider
>>> http://www.liquid-reality.de
>>>
>>> Open Source Architect
>>> http://www.talend.com
>>>
>>
>>
>
>
> --
> Christian Schneider
> http://www.liquid-reality.de
>
> Open Source Architect
> http://www.talend.com
>



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Claus Ibsen-2
Hi

Yeah so the infinite recursion is surely a bug. However its only
triggered when you

- use global onException
- call a direct route from the onException
- causes a 2nd exception

When using route scoped onException this does not happen as the error
handler works a little bit different when its route scoped vs global
scoped. In route scope the FatalFallbackErrorHandler weighs in and
detect the 2nd exception and prevents the recursion.

I have an improved patch in the works based on your commits. Also I am
making sure the two exceptions are not lost, so you have that
information in the stacktrace being logged, and in the right order
(new -> old).



On Tue, May 9, 2017 at 12:57 PM, Claus Ibsen <[hidden email]> wrote:

> Hi
>
> I ought to have cleared up some room for me to have time tomorrow
> morning to take a look. This sort of thing requires a "calm period"
> where you are not disturbed.
>
>
>
> On Mon, May 8, 2017 at 2:37 PM, Christian Schneider
> <[hidden email]> wrote:
>> Hi Claus,
>>
>> that is fine. I was hoping for you to take look.
>>
>> Christian
>>
>>
>> On 08.05.2017 14:30, Claus Ibsen wrote:
>>>
>>> On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
>>> <[hidden email]> wrote:
>>>>
>>>> Hi Zoran,
>>>>
>>>> I have merged your improvements into the branch.
>>>>
>>>> I will wait one more day for feedback and then merge into master.
>>>>
>>> Can you wait some longer. Some of us have been traveling all last week
>>> and are back in our office with jet-lag and a ton of email to catch
>>> up.
>>>
>>> I will take a look at this later this week.
>>>
>>>
>>>
>>>> Christian
>>>>
>>>>
>>>> On 08.05.2017 11:57, Zoran Regvart wrote:
>>>>>
>>>>> Hi Christian,
>>>>> I think that your initial example of the recursion is a simpler
>>>>> example for the unit test, so with that and a minor reformat of the
>>>>> source code I've committed this to my GitHub fork:
>>>>>
>>>>>
>>>>>
>>>>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>>>>
>>>>> have a look, thanks :)
>>>>>
>>>>> zoran
>>>>>
>>>>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>>>>> <[hidden email]> wrote:
>>>>>>
>>>>>> I have pushed a test and a possible fix to
>>>>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>>>>
>>>>>> As the code around error handling is pretty difficult to understand I
>>>>>> am
>>>>>> not
>>>>>> sure if my solution is good. I would be happy if someone could review
>>>>>> my
>>>>>> change.
>>>>>>
>>>>>> Christian
>>>>>>
>>>>>>
>>>>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>>>>
>>>>>>> I have the routes below. When I send a message to direct:test I get an
>>>>>>> infinite recursion of exceptions.
>>>>>>> The reason is that the onException handler also seems to be called for
>>>>>>> the
>>>>>>> direct:handle_er that is called when handling the
>>>>>>> first exception. In case such a handler route also throws an exception
>>>>>>> the
>>>>>>> recursion happens.
>>>>>>>
>>>>>>> Is this expected or a bug?
>>>>>>> If it is not a bug what do we recommend our users to avoid the
>>>>>>> recursion?
>>>>>>>
>>>>>>>                   onException(Throwable.class)
>>>>>>>                   .to("direct:handle_er");
>>>>>>>
>>>>>>>                   from("direct:test")
>>>>>>>                   .throwException(new RuntimeException())
>>>>>>>                   .to("log:test2");
>>>>>>>
>>>>>>>                   from("direct:handle_er")
>>>>>>>                   .throwException(new RuntimeException());
>>>>>>>
>>>>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>>>>
>>>>>>> Christian
>>>>>>>
>>>>>> --
>>>>>> Christian Schneider
>>>>>> http://www.liquid-reality.de
>>>>>>
>>>>>> Open Source Architect
>>>>>> http://www.talend.com
>>>>>>
>>>>>
>>>>
>>>> --
>>>> Christian Schneider
>>>> http://www.liquid-reality.de
>>>>
>>>> Open Source Architect
>>>> http://www.talend.com
>>>>
>>>
>>>
>>
>>
>> --
>> Christian Schneider
>> http://www.liquid-reality.de
>>
>> Open Source Architect
>> http://www.talend.com
>>
>
>
>
> --
> Claus Ibsen
> -----------------
> http://davsclaus.com @davsclaus
> Camel in Action 2: https://www.manning.com/ibsen2



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Claus Ibsen-2
In reply to this post by Christian Schneider
On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
<[hidden email]> wrote:
> Hi Zoran,
>
> I have merged your improvements into the branch.
>
> I will wait one more day for feedback and then merge into master.
>

btw you guys must do a full test of camel-core in the future,
before doing any such merges.

This code change causes a few unit test errors

Tests run: 5945, Failures: 4, Errors: 2, Skipped: 4



The work-around / solution to your use-case is to disable the error
handler on the route which you use with your onException

from("direct:handle").errorHandler(noErrorHandler())
    .throwException(new NullPointerException());






> Christian
>
>
> On 08.05.2017 11:57, Zoran Regvart wrote:
>>
>> Hi Christian,
>> I think that your initial example of the recursion is a simpler
>> example for the unit test, so with that and a minor reformat of the
>> source code I've committed this to my GitHub fork:
>>
>>
>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>
>> have a look, thanks :)
>>
>> zoran
>>
>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>> <[hidden email]> wrote:
>>>
>>> I have pushed a test and a possible fix to
>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>
>>> As the code around error handling is pretty difficult to understand I am
>>> not
>>> sure if my solution is good. I would be happy if someone could review my
>>> change.
>>>
>>> Christian
>>>
>>>
>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>
>>>> I have the routes below. When I send a message to direct:test I get an
>>>> infinite recursion of exceptions.
>>>> The reason is that the onException handler also seems to be called for
>>>> the
>>>> direct:handle_er that is called when handling the
>>>> first exception. In case such a handler route also throws an exception
>>>> the
>>>> recursion happens.
>>>>
>>>> Is this expected or a bug?
>>>> If it is not a bug what do we recommend our users to avoid the
>>>> recursion?
>>>>
>>>>                  onException(Throwable.class)
>>>>                  .to("direct:handle_er");
>>>>
>>>>                  from("direct:test")
>>>>                  .throwException(new RuntimeException())
>>>>                  .to("log:test2");
>>>>
>>>>                  from("direct:handle_er")
>>>>                  .throwException(new RuntimeException());
>>>>
>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>
>>>> Christian
>>>>
>>>
>>> --
>>> Christian Schneider
>>> http://www.liquid-reality.de
>>>
>>> Open Source Architect
>>> http://www.talend.com
>>>
>>
>>
>
>
> --
> Christian Schneider
> http://www.liquid-reality.de
>
> Open Source Architect
> http://www.talend.com
>



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Claus Ibsen-2
In reply to this post by Claus Ibsen-2
Hi

Just an update, so I got a potential fix that makes all tests pass in
camel-core if I run them with mvn clean install, but for some odd
reason there is one unit test that fails if I run it individually:
ErrorOccuredInOnExceptionRoute

Will continue tomorrow

On Wed, May 10, 2017 at 11:02 AM, Claus Ibsen <[hidden email]> wrote:

> Hi
>
> Yeah so the infinite recursion is surely a bug. However its only
> triggered when you
>
> - use global onException
> - call a direct route from the onException
> - causes a 2nd exception
>
> When using route scoped onException this does not happen as the error
> handler works a little bit different when its route scoped vs global
> scoped. In route scope the FatalFallbackErrorHandler weighs in and
> detect the 2nd exception and prevents the recursion.
>
> I have an improved patch in the works based on your commits. Also I am
> making sure the two exceptions are not lost, so you have that
> information in the stacktrace being logged, and in the right order
> (new -> old).
>
>
>
> On Tue, May 9, 2017 at 12:57 PM, Claus Ibsen <[hidden email]> wrote:
>> Hi
>>
>> I ought to have cleared up some room for me to have time tomorrow
>> morning to take a look. This sort of thing requires a "calm period"
>> where you are not disturbed.
>>
>>
>>
>> On Mon, May 8, 2017 at 2:37 PM, Christian Schneider
>> <[hidden email]> wrote:
>>> Hi Claus,
>>>
>>> that is fine. I was hoping for you to take look.
>>>
>>> Christian
>>>
>>>
>>> On 08.05.2017 14:30, Claus Ibsen wrote:
>>>>
>>>> On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
>>>> <[hidden email]> wrote:
>>>>>
>>>>> Hi Zoran,
>>>>>
>>>>> I have merged your improvements into the branch.
>>>>>
>>>>> I will wait one more day for feedback and then merge into master.
>>>>>
>>>> Can you wait some longer. Some of us have been traveling all last week
>>>> and are back in our office with jet-lag and a ton of email to catch
>>>> up.
>>>>
>>>> I will take a look at this later this week.
>>>>
>>>>
>>>>
>>>>> Christian
>>>>>
>>>>>
>>>>> On 08.05.2017 11:57, Zoran Regvart wrote:
>>>>>>
>>>>>> Hi Christian,
>>>>>> I think that your initial example of the recursion is a simpler
>>>>>> example for the unit test, so with that and a minor reformat of the
>>>>>> source code I've committed this to my GitHub fork:
>>>>>>
>>>>>>
>>>>>>
>>>>>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>>>>>
>>>>>> have a look, thanks :)
>>>>>>
>>>>>> zoran
>>>>>>
>>>>>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>>>>>> <[hidden email]> wrote:
>>>>>>>
>>>>>>> I have pushed a test and a possible fix to
>>>>>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>>>>>
>>>>>>> As the code around error handling is pretty difficult to understand I
>>>>>>> am
>>>>>>> not
>>>>>>> sure if my solution is good. I would be happy if someone could review
>>>>>>> my
>>>>>>> change.
>>>>>>>
>>>>>>> Christian
>>>>>>>
>>>>>>>
>>>>>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>>>>>
>>>>>>>> I have the routes below. When I send a message to direct:test I get an
>>>>>>>> infinite recursion of exceptions.
>>>>>>>> The reason is that the onException handler also seems to be called for
>>>>>>>> the
>>>>>>>> direct:handle_er that is called when handling the
>>>>>>>> first exception. In case such a handler route also throws an exception
>>>>>>>> the
>>>>>>>> recursion happens.
>>>>>>>>
>>>>>>>> Is this expected or a bug?
>>>>>>>> If it is not a bug what do we recommend our users to avoid the
>>>>>>>> recursion?
>>>>>>>>
>>>>>>>>                   onException(Throwable.class)
>>>>>>>>                   .to("direct:handle_er");
>>>>>>>>
>>>>>>>>                   from("direct:test")
>>>>>>>>                   .throwException(new RuntimeException())
>>>>>>>>                   .to("log:test2");
>>>>>>>>
>>>>>>>>                   from("direct:handle_er")
>>>>>>>>                   .throwException(new RuntimeException());
>>>>>>>>
>>>>>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>>>>>
>>>>>>>> Christian
>>>>>>>>
>>>>>>> --
>>>>>>> Christian Schneider
>>>>>>> http://www.liquid-reality.de
>>>>>>>
>>>>>>> Open Source Architect
>>>>>>> http://www.talend.com
>>>>>>>
>>>>>>
>>>>>
>>>>> --
>>>>> Christian Schneider
>>>>> http://www.liquid-reality.de
>>>>>
>>>>> Open Source Architect
>>>>> http://www.talend.com
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Christian Schneider
>>> http://www.liquid-reality.de
>>>
>>> Open Source Architect
>>> http://www.talend.com
>>>
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> http://davsclaus.com @davsclaus
>> Camel in Action 2: https://www.manning.com/ibsen2
>
>
>
> --
> Claus Ibsen
> -----------------
> http://davsclaus.com @davsclaus
> Camel in Action 2: https://www.manning.com/ibsen2



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Claus Ibsen-2
Hi

Okay I pushed some code changes to that branch, and am currently
testing those on the latest master branch before merging.


On Wed, May 10, 2017 at 4:58 PM, Claus Ibsen <[hidden email]> wrote:

> Hi
>
> Just an update, so I got a potential fix that makes all tests pass in
> camel-core if I run them with mvn clean install, but for some odd
> reason there is one unit test that fails if I run it individually:
> ErrorOccuredInOnExceptionRoute
>
> Will continue tomorrow
>
> On Wed, May 10, 2017 at 11:02 AM, Claus Ibsen <[hidden email]> wrote:
>> Hi
>>
>> Yeah so the infinite recursion is surely a bug. However its only
>> triggered when you
>>
>> - use global onException
>> - call a direct route from the onException
>> - causes a 2nd exception
>>
>> When using route scoped onException this does not happen as the error
>> handler works a little bit different when its route scoped vs global
>> scoped. In route scope the FatalFallbackErrorHandler weighs in and
>> detect the 2nd exception and prevents the recursion.
>>
>> I have an improved patch in the works based on your commits. Also I am
>> making sure the two exceptions are not lost, so you have that
>> information in the stacktrace being logged, and in the right order
>> (new -> old).
>>
>>
>>
>> On Tue, May 9, 2017 at 12:57 PM, Claus Ibsen <[hidden email]> wrote:
>>> Hi
>>>
>>> I ought to have cleared up some room for me to have time tomorrow
>>> morning to take a look. This sort of thing requires a "calm period"
>>> where you are not disturbed.
>>>
>>>
>>>
>>> On Mon, May 8, 2017 at 2:37 PM, Christian Schneider
>>> <[hidden email]> wrote:
>>>> Hi Claus,
>>>>
>>>> that is fine. I was hoping for you to take look.
>>>>
>>>> Christian
>>>>
>>>>
>>>> On 08.05.2017 14:30, Claus Ibsen wrote:
>>>>>
>>>>> On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
>>>>> <[hidden email]> wrote:
>>>>>>
>>>>>> Hi Zoran,
>>>>>>
>>>>>> I have merged your improvements into the branch.
>>>>>>
>>>>>> I will wait one more day for feedback and then merge into master.
>>>>>>
>>>>> Can you wait some longer. Some of us have been traveling all last week
>>>>> and are back in our office with jet-lag and a ton of email to catch
>>>>> up.
>>>>>
>>>>> I will take a look at this later this week.
>>>>>
>>>>>
>>>>>
>>>>>> Christian
>>>>>>
>>>>>>
>>>>>> On 08.05.2017 11:57, Zoran Regvart wrote:
>>>>>>>
>>>>>>> Hi Christian,
>>>>>>> I think that your initial example of the recursion is a simpler
>>>>>>> example for the unit test, so with that and a minor reformat of the
>>>>>>> source code I've committed this to my GitHub fork:
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>>>>>>
>>>>>>> have a look, thanks :)
>>>>>>>
>>>>>>> zoran
>>>>>>>
>>>>>>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>>>>>>> <[hidden email]> wrote:
>>>>>>>>
>>>>>>>> I have pushed a test and a possible fix to
>>>>>>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>>>>>>
>>>>>>>> As the code around error handling is pretty difficult to understand I
>>>>>>>> am
>>>>>>>> not
>>>>>>>> sure if my solution is good. I would be happy if someone could review
>>>>>>>> my
>>>>>>>> change.
>>>>>>>>
>>>>>>>> Christian
>>>>>>>>
>>>>>>>>
>>>>>>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>>>>>>
>>>>>>>>> I have the routes below. When I send a message to direct:test I get an
>>>>>>>>> infinite recursion of exceptions.
>>>>>>>>> The reason is that the onException handler also seems to be called for
>>>>>>>>> the
>>>>>>>>> direct:handle_er that is called when handling the
>>>>>>>>> first exception. In case such a handler route also throws an exception
>>>>>>>>> the
>>>>>>>>> recursion happens.
>>>>>>>>>
>>>>>>>>> Is this expected or a bug?
>>>>>>>>> If it is not a bug what do we recommend our users to avoid the
>>>>>>>>> recursion?
>>>>>>>>>
>>>>>>>>>                   onException(Throwable.class)
>>>>>>>>>                   .to("direct:handle_er");
>>>>>>>>>
>>>>>>>>>                   from("direct:test")
>>>>>>>>>                   .throwException(new RuntimeException())
>>>>>>>>>                   .to("log:test2");
>>>>>>>>>
>>>>>>>>>                   from("direct:handle_er")
>>>>>>>>>                   .throwException(new RuntimeException());
>>>>>>>>>
>>>>>>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>>>>>>
>>>>>>>>> Christian
>>>>>>>>>
>>>>>>>> --
>>>>>>>> Christian Schneider
>>>>>>>> http://www.liquid-reality.de
>>>>>>>>
>>>>>>>> Open Source Architect
>>>>>>>> http://www.talend.com
>>>>>>>>
>>>>>>>
>>>>>>
>>>>>> --
>>>>>> Christian Schneider
>>>>>> http://www.liquid-reality.de
>>>>>>
>>>>>> Open Source Architect
>>>>>> http://www.talend.com
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Christian Schneider
>>>> http://www.liquid-reality.de
>>>>
>>>> Open Source Architect
>>>> http://www.talend.com
>>>>
>>>
>>>
>>>
>>> --
>>> Claus Ibsen
>>> -----------------
>>> http://davsclaus.com @davsclaus
>>> Camel in Action 2: https://www.manning.com/ibsen2
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> http://davsclaus.com @davsclaus
>> Camel in Action 2: https://www.manning.com/ibsen2
>
>
>
> --
> Claus Ibsen
> -----------------
> http://davsclaus.com @davsclaus
> Camel in Action 2: https://www.manning.com/ibsen2



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Claus Ibsen-2
Hi

I have pushed a fix for the master, 2.19.x and 2.18.x branches. I ran
a complete test on master and ensured it all still works, and the
recursion problem is only in those unit tests that triggered those. We
log a special WARN when the circular error-handler is detected.



On Thu, May 11, 2017 at 1:19 PM, Claus Ibsen <[hidden email]> wrote:

> Hi
>
> Okay I pushed some code changes to that branch, and am currently
> testing those on the latest master branch before merging.
>
>
> On Wed, May 10, 2017 at 4:58 PM, Claus Ibsen <[hidden email]> wrote:
>> Hi
>>
>> Just an update, so I got a potential fix that makes all tests pass in
>> camel-core if I run them with mvn clean install, but for some odd
>> reason there is one unit test that fails if I run it individually:
>> ErrorOccuredInOnExceptionRoute
>>
>> Will continue tomorrow
>>
>> On Wed, May 10, 2017 at 11:02 AM, Claus Ibsen <[hidden email]> wrote:
>>> Hi
>>>
>>> Yeah so the infinite recursion is surely a bug. However its only
>>> triggered when you
>>>
>>> - use global onException
>>> - call a direct route from the onException
>>> - causes a 2nd exception
>>>
>>> When using route scoped onException this does not happen as the error
>>> handler works a little bit different when its route scoped vs global
>>> scoped. In route scope the FatalFallbackErrorHandler weighs in and
>>> detect the 2nd exception and prevents the recursion.
>>>
>>> I have an improved patch in the works based on your commits. Also I am
>>> making sure the two exceptions are not lost, so you have that
>>> information in the stacktrace being logged, and in the right order
>>> (new -> old).
>>>
>>>
>>>
>>> On Tue, May 9, 2017 at 12:57 PM, Claus Ibsen <[hidden email]> wrote:
>>>> Hi
>>>>
>>>> I ought to have cleared up some room for me to have time tomorrow
>>>> morning to take a look. This sort of thing requires a "calm period"
>>>> where you are not disturbed.
>>>>
>>>>
>>>>
>>>> On Mon, May 8, 2017 at 2:37 PM, Christian Schneider
>>>> <[hidden email]> wrote:
>>>>> Hi Claus,
>>>>>
>>>>> that is fine. I was hoping for you to take look.
>>>>>
>>>>> Christian
>>>>>
>>>>>
>>>>> On 08.05.2017 14:30, Claus Ibsen wrote:
>>>>>>
>>>>>> On Mon, May 8, 2017 at 1:57 PM, Christian Schneider
>>>>>> <[hidden email]> wrote:
>>>>>>>
>>>>>>> Hi Zoran,
>>>>>>>
>>>>>>> I have merged your improvements into the branch.
>>>>>>>
>>>>>>> I will wait one more day for feedback and then merge into master.
>>>>>>>
>>>>>> Can you wait some longer. Some of us have been traveling all last week
>>>>>> and are back in our office with jet-lag and a ton of email to catch
>>>>>> up.
>>>>>>
>>>>>> I will take a look at this later this week.
>>>>>>
>>>>>>
>>>>>>
>>>>>>> Christian
>>>>>>>
>>>>>>>
>>>>>>> On 08.05.2017 11:57, Zoran Regvart wrote:
>>>>>>>>
>>>>>>>> Hi Christian,
>>>>>>>> I think that your initial example of the recursion is a simpler
>>>>>>>> example for the unit test, so with that and a minor reformat of the
>>>>>>>> source code I've committed this to my GitHub fork:
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> https://github.com/zregvart/camel/commit/d76f75ea46b55b16af9e0ae05bfbb3df271545bd
>>>>>>>>
>>>>>>>> have a look, thanks :)
>>>>>>>>
>>>>>>>> zoran
>>>>>>>>
>>>>>>>> On Fri, May 5, 2017 at 5:43 PM, Christian Schneider
>>>>>>>> <[hidden email]> wrote:
>>>>>>>>>
>>>>>>>>> I have pushed a test and a possible fix to
>>>>>>>>> https://github.com/apache/camel/tree/CAMEL-11229
>>>>>>>>>
>>>>>>>>> As the code around error handling is pretty difficult to understand I
>>>>>>>>> am
>>>>>>>>> not
>>>>>>>>> sure if my solution is good. I would be happy if someone could review
>>>>>>>>> my
>>>>>>>>> change.
>>>>>>>>>
>>>>>>>>> Christian
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On 04.05.2017 17:30, Christian Schneider wrote:
>>>>>>>>>>
>>>>>>>>>> I have the routes below. When I send a message to direct:test I get an
>>>>>>>>>> infinite recursion of exceptions.
>>>>>>>>>> The reason is that the onException handler also seems to be called for
>>>>>>>>>> the
>>>>>>>>>> direct:handle_er that is called when handling the
>>>>>>>>>> first exception. In case such a handler route also throws an exception
>>>>>>>>>> the
>>>>>>>>>> recursion happens.
>>>>>>>>>>
>>>>>>>>>> Is this expected or a bug?
>>>>>>>>>> If it is not a bug what do we recommend our users to avoid the
>>>>>>>>>> recursion?
>>>>>>>>>>
>>>>>>>>>>                   onException(Throwable.class)
>>>>>>>>>>                   .to("direct:handle_er");
>>>>>>>>>>
>>>>>>>>>>                   from("direct:test")
>>>>>>>>>>                   .throwException(new RuntimeException())
>>>>>>>>>>                   .to("log:test2");
>>>>>>>>>>
>>>>>>>>>>                   from("direct:handle_er")
>>>>>>>>>>                   .throwException(new RuntimeException());
>>>>>>>>>>
>>>>>>>>>> See also https://issues.apache.org/jira/browse/CAMEL-11229
>>>>>>>>>>
>>>>>>>>>> Christian
>>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Christian Schneider
>>>>>>>>> http://www.liquid-reality.de
>>>>>>>>>
>>>>>>>>> Open Source Architect
>>>>>>>>> http://www.talend.com
>>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Christian Schneider
>>>>>>> http://www.liquid-reality.de
>>>>>>>
>>>>>>> Open Source Architect
>>>>>>> http://www.talend.com
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Christian Schneider
>>>>> http://www.liquid-reality.de
>>>>>
>>>>> Open Source Architect
>>>>> http://www.talend.com
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Claus Ibsen
>>>> -----------------
>>>> http://davsclaus.com @davsclaus
>>>> Camel in Action 2: https://www.manning.com/ibsen2
>>>
>>>
>>>
>>> --
>>> Claus Ibsen
>>> -----------------
>>> http://davsclaus.com @davsclaus
>>> Camel in Action 2: https://www.manning.com/ibsen2
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> http://davsclaus.com @davsclaus
>> Camel in Action 2: https://www.manning.com/ibsen2
>
>
>
> --
> Claus Ibsen
> -----------------
> http://davsclaus.com @davsclaus
> Camel in Action 2: https://www.manning.com/ibsen2



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Reply | Threaded
Open this post in threaded view
|

Re: Infinite recursion of exceptions. Is it a bug?

Christian Schneider
Many thanks Claus. I really appreciate your help on this.

About the test failures. I had a few test failures on core before the
change so I did not spot the additional ones. I typically try to only
commit if I do not add test failures.
I waited with the commit anyway as I was not sure my solution is
conceptually correct.

Christian

On 11.05.2017 22:31, Claus Ibsen wrote:
> Hi
>
> I have pushed a fix for the master, 2.19.x and 2.18.x branches. I ran
> a complete test on master and ensured it all still works, and the
> recursion problem is only in those unit tests that triggered those. We
> log a special WARN when the circular error-handler is detected.

--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com