Uploaded image for project: 'SwitchYard'
  1. SwitchYard
  2. SWITCHYARD-1927

Caught exception in CamelRoute leads to timeout

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 1.0
    • Fix Version/s: 2.0
    • Component/s: core
    • Labels:
      None
    • Environment:

      Switchyard 1.1.0-Final

      Description

      A bug in camel leads to the situation that a camel route which uses onException to handle exceptions gracefully, does not return to the caller and produces a timeout.

      I could track the behaviour down to the class org.switchyard.bus.camel.CamelExchangeBusRouteBuilder which uses a camel try-catch-finally block to handle exceptions for the routing of switchyard services. The finally block consists of two Processors:

      InterceptProcessor
      ConsumerCallbackProcessor

      Due to a camel bug see #1 only the first processor of a finally block is executed. The second processor, which returns the exchange to the caller, is ommited, as camel thinks some other exception happened.

      A possible workaround would be the addition of another processor that removes the Exchange.ERRORHANDLER_HANDLED property from the exchange or the upgrade the version of camel.

      #1 http://stackoverflow.com/questions/20399863/if-route-threw-exception-and-handled-is-set-to-true-only-first-processor-in-dof

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  kcbabo Keith Babo
                  Reporter:
                  sdirbach Sascha Dirbach
                • Votes:
                  1 Vote for this issue
                  Watchers:
                  4 Start watching this issue

                  Dates

                  • Due:
                    Created:
                    Updated:
                    Resolved: