Condition
Condition is used to check a condition and execute the flow in a different route depending on this condition.
Basically, it checks if a condition is true and redirects the flow based on the condition. This condition can be expressed in various formats such as XPath, JSONPath, or a general expression. In instances where none of the conditions are met, opting for the "Default Route" ensures the continuation of the default path.
XPath
/BankServiceCode = 'bankcode1'
/BankServiceCode != 'bankcode1'
//BankServiceCode = 'bankcode1' and //AccountCode = '12345'
JSON Path
$.customer[?(@.age > 18 || @.car == 'Mercedes')] # logical or
$.customer[?(@.age < 18 && @.hobby == 'Biking' )] # logical and
Expression
${exchangeProperty.car} == 'Car Brand'
${header.CamelFileName} == 'Sample_File.txt'
Camel Simple Language can be using for this type.
Visit the official Camel Simple Language page .