Skip to main content

Routing and flow reference

These processors are always part of the server; they choose ports, split and batch messages, pace them, repeat a step, run another workflow or wait for an answer. Options typed EXPRESSION are SpEL evaluated against the message: payload.x reads a payload field and metadata.x a metadata entry. These plugins do not resolve ${...} in their options unless a row says so. Default node timeout is 30 seconds unless stated.

BRANCH

Routes each message to the port named by the first matching case.
  • Output ports: the distinct values of cases, plus defaultPort and errorPort; default when none are set.
  • Errors: Invalid or missing mode. Must be SELECT_KEY or EXPRESSION; selector is mandatory for SELECT_KEY mode; cases map is mandatory and cannot be empty. Validation in a workflow fails when a case routes to a port that has no outgoing edge.

FILTER

Passes a message when a predicate is true; otherwise drops it or routes it to discardPort.
  • Output ports: default, plus discardPort when set.
  • Errors: condition is mandatory for Filter plugin; Unsupported engine: <name>; the engine REGO is reserved and rejected with REGO engine is reserved for future use and not yet implemented.; an evaluation error is Filter evaluation failed for condition: <condition>.

SPLITTER

Splits a composite message into one message per item.
  • Output ports: default, plus errorPort when set.
  • Errors: itemsPath mandatory; itemsPath null; Mapping failed.

AGGREGATE

Batches messages into one message holding the list of their payloads; the reverse of SPLITTER.
  • Output port: default. The remainder is flushed when the stream completes.
  • Errors: size must be a positive number.

RECIPIENT_LIST

Copies one message to several ports.
  • Output ports: the recipients plus errorPort in STATIC mode; * (any port) in the other modes; default for an empty STATIC list.
  • Errors: recipients list is mandatory for STATIC mode; expression is mandatory for DYNAMIC mode; sourceField is mandatory for EXTERNAL mode; Invalid mode: <mode>.

DELAY

Delays each message by a fixed time; messages are released one at a time, in order.
  • Output port: default.
  • Errors: delayMs must be a positive number.

LOOP_PREDICATE and LOOP_STREAM

Run a target processor repeatedly until a condition is met. LOOP_PREDICATE emits only the final successful message; LOOP_STREAM flattens every message the iterations produce into one stream. Both take the same options. failureStrategy: ABORT aborts the run; RETRY repeats the iteration with the same input; SKIP drops the failed iteration and goes on; ESCALATE ends the whole run with a RunAbortedException that nothing retries or routes. RETRY and SKIP each use up an iteration, so maxIterations and maxDuration bound them.
  • Output port: default.
  • Errors: Target plugin not found: <id>; Target plugin must be a ProcessorPlugin: <id>.

SUB_WORKFLOW

Runs another workflow of the same session for each message and emits its results.
  • Output ports: default; with routeByOutcome, success, failure, retry, escalate.
  • Payload: {executionId, results[], status, outcome?, reason?}. outcome is the one the child’s OUTCOME_TERMINAL reached (SUCCESS, RETRY, ESCALATE, FAILED) and is absent when it reached none.
  • Limits: nesting is limited to 5 levels. yukta.execution.max-concurrent must allow the parent and its children together. Default node timeout is timeoutSeconds plus 10 seconds.
  • Errors: workflowId must be a non-empty workflow id; payload must be a map; timeoutSeconds must be a positive number; concurrency must be a number from 1 to 16.

WAIT_FOR_SIGNAL

Holds a message until a person answers. The wait is an input request of kind APPROVAL and risk HIGH, so only a person can answer it.
  • Output port: default. Any decision other than reject lets the message through; it is in metadata signal.decision.
  • Default node timeout: timeoutSeconds plus 30 seconds.
  • Errors: signal must be a non-empty name of at most 128 characters; timeoutSeconds must be a positive number.

ASK_INPUT

Asks a supervisor, a person or an agent a typed question per message and waits for the answer. Needs the control plane.
  • Output port: default. Metadata gains input.requestId, input.decision, input.text, input.data, input.responder, input.confidence. A rejection is a decision, not an error.
  • Replay: the answer is recorded under the node input:<node>; a resumed run replays only finished nodes, so a re-produced message asks again.
  • Default node timeout: ttlSeconds plus 30 seconds.
  • Errors: The prompt of ASK_INPUT is empty; ttlSeconds must be a positive number; kind must be APPROVAL, CHOICE, TEXT or STRUCTURED; onTimeout must be FAIL, CONTINUE or USE_DEFAULT; context must be a map of at most 16 entries.

KV_STORE

A shared in-memory key-value store for state across runs. Needs the control plane.
  • Output port: default; payload {key, value}, value is null when absent.
  • Errors: op must be one of [...]; key is required (config or payload.key); put requires payload.value; incr requires a whole-number payload.value.