Skip to main content
Retries, error routing and time limits are not plugin features. They are applied by the engine around every node, and you control them with a reserved engine object inside a node’s config. The plugin never sees it.
The workflow schema is pre-beta. The engine option names may change before v0.1.0.

The engine object

A malformed policy is rejected when the workflow is validated, with the node id and the option at fault. Unknown keys are rejected, maxBackoffMs must be below the node timeout, retryOn and noRetryOn must not share an entry, and deadlineMs must be above elementTimeoutMs.

Retry

Retry is per message, so use it on processors that handle one message at a time. A node with retry, onError or elementTimeoutMs calls its plugin once per message, and the message carries an attempt label (1, 2, …).
  • A plugin that reports invalid input (a bad request, not a transient fault) is never retried.
  • retryOn and noRetryOn list error type names to include or exclude. Subclasses and causes match, and noRetryOn wins.
  • A retried plugin can see the same message twice, so de-duplicate on the message id.

Error routing

With onError: ROUTE, a message that fails all its attempts is sent to the node’s error port, tagged with failure.attempts, failure.exception and failure.time (plus origDest and failureReason). Wire an edge with "sourcePort": "error" to a dead-letter node:
An edge without a port never carries dead letters.

All-or-nothing output

With retry or onError of CONTINUE or ROUTE, whatever an attempt emitted before it failed is held back and dropped. A retry or a dead letter therefore never lands on top of a partial result. The cost is that one message’s output is buffered until its attempt ends.

Failure budget

CONTINUE and ROUTE keep a flow alive by absorbing failures, which can hide a systematic problem. A failure budget caps that: once more than maxFailures messages fail inside windowMs in one execution, the node fails instead, so silent data loss cannot continue unnoticed.

How failures propagate