Decision
The standard decision from the component palette has different modes it can operate in.
-
An activity may set its outcome
for example when reading one line of a datasource everytime, data was either read (workflow continues using the
next
edge of the decision) or no more lines are present (end reached
edge) -
Existing data may be matched via a regular expression
yes
/no
-
The spring expression language 'SpEL' is available for more advanced cases
Activity-based decision​
This is the regular decision that is used when an activity has determined one out of several ways to continue the workflow. E.g. [CSV data](../input/CSV data.md) has 'next' and 'end reached' depending on available data. The accompanying decision would model two outgoing edges with the action labels mentioned above.
Workflow continuation: The available continuations can be selected via the drop-down menu of the outgoing edges.
RegEx-Match decision​
Uses a regular expression matcher in multiline mode and uses the expanded character sequence from
a variable.
You can use this decision to create a keyword matcher easily; E.g. \b(?:keyword1|keyword2|text3)\b
will
match 'keyword1', 'keyword2' or 'text3'.
The input text can be a variable such as ${email_text}
to match text from an incoming E-Mail or
any other text that was collected during execution of the workflow.
Regexr.com is a good online resource to create or test your regular expressions.
Workflow continuation:
The decision continues the workflow by taking the edge yes
if matched or no
if the expression didn't match.
Variable Expression​
Logical operator to compare one or more variables with the possibility to access datastructures or lists. Evaluates Spring expression language (SpEL) defined at an outgoing edge. Continues the particular path if it evaluated to true.
Workflow continuation:
- takes the outgoing edge with the first expression that evaluated to true
- 'next' if no expression evaluated to true