Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-11229

Infinite recursion if exception happens inside exception handler

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.18.3
    • Fix Version/s: 2.18.4, 2.19.1, 2.20.0
    • Component/s: camel-core
    • Labels:
      None
    • Estimated Complexity:
      Advanced

      Description

      Use an onException handler like this:

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

      If the main route throws an exception then this will create an infinite recursion of exceptions.

      I would expect that camel handles the exception inside an onException handler differently. So the onException is not called again.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                davsclaus Claus Ibsen
                Reporter:
                cschneider Christian Schneider
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: