Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Wiki Markup
{snippet:id=example|lang=xml|url=activemq/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/spring/xml/buildSimpleRouteWithChoice.xml}

Choice without otherwise

If you use a choice without adding an otherwise, any unmatched exchanges will be dropped by default. If you prefer to have an exception for an unmatched exchange, you can add a throwFault to the otherwise.

Code Block
java
java

  ....otherwise().throwFault("No matching when clause found on choice block");
Include Page
CAMEL:Using This Pattern
CAMEL:Using This Pattern