Skip to content
Development preview · 2.0.0-SNAPSHOT

Node support

Check support for the engine you use: ProcessEngine runs flows in memory, while Durable persists execution state. They support different BPMN and TBBPM elements. An element must pass that engine’s semantic validation and have a runtime implementation before it can execute; support in one engine does not imply support in the other.

  • start - Start node
  • end - End node
  • autoTask - Auto task node
  • scriptTask - Script task node
  • exclusive - Exclusive gateway
  • parallel - Parallel gateway
  • inclusive - Inclusive gateway
  • while - Bounded conditional loop
  • foreach - Sequential collection loop; parallel mode requires Durable
  • subBpm - Embedded BPM scope
  • bpmCall - Call another BPM definition
  • continue - Skip the rest of the current iteration and begin the next
  • break - Exit the current loop

Both sequential and parallel foreach support ordered output aggregation. Each iteration starts with the output element variable reset to its declared default; the complete collection is written to the output variable only when the loop exits.

  • waitTask - Wait task, optionally qualified by an event name

On ProcessEngine, eligible Wait nodes are named entries for fresh trigger(...) invocations. A Wait must be in the root process, outside concurrent regions, and have no deadline, iteration wrapper, output mappings, outcomeVariable, or resolvedAtVariable. The caller provides the state for each invocation. Durable persists each Wait occurrence, including those in supported scopes and bounded loops; completion requires the token for that occurrence and exactly the declared payload fields (an empty map when no outputs are declared).

  • timerTask - Saves a Timer and suspends the current execution path until it is due. Specify a relative delay with duration or durationExpression, or an absolute wake time with wakeAt or wakeAtExpression. Other runnable branches in the same Run can continue.

timerTask is supported by the TBBPM schema and Durable compiler, including inside loops. ProcessEngine rejects the entire definition during preparation if it contains a Timer, even on a conditional branch.

Every executable Durable Action must explicitly declare its execution mode: execution="replayable|effect" on a TBBPM action or BPMN cf:action, and cf:execution="replayable|effect" on a BPMN scriptTask. An omitted mode remains unspecified and fails Durable preparation. An Effect calls a Java method, a host component method, or a script in a registered language. The Durable kernel records its dispatch state and outcome, including an unknown outcome.

Durable TBBPM supports start, end, autoTask, scriptTask, exclusive, waitTask, timerTask, while, foreach, break, continue, structured parallel/inclusive, subBpm, and bpmCall. Parallel and Inclusive persist branch progress and merge results in a stable order. Durable supports Process calls inside concurrent gateway scopes. ProcessEngine rejects concurrent gateway splits inside nested scopes, suspending nodes in concurrent regions, and Effect Actions during preparation. Within one process definition, Process calls inside parallel foreach iterations, parallel foreach nested inside a concurrent scope, and concurrent forks inside parallel foreach iterations remain unsupported.

In a directly supplied definition, bpmCall specifies an exact application-classpath location or an exact Version. An exact-Version graph uses Version-only dependencies. An Alias is resolved only when starting the root process, so every static call site remains bound to an exact target. A child call creates a ProcessInvocation frame within the same Run, not a second Run.

Exclusive-gateway conditions, While conditions, Timer expressions, guards, and transition conditions use generated Java. Actions can use a registered ScriptExecutor; CompileFlow does not require a single script language. Every TBBPM while must declare maxIterations. This loop limit is separate from the Durable Turn budget, which limits the work in one execution slice. BPMN’s loop limits are described under Activity Wrappers below.

See the TBBPM specification and Durable Process guide.

  • note - Diagram annotation with no execution behavior
  • startEvent - Start event
  • endEvent - End event
  • intermediateCatchEvent with messageEventDefinition - Its event name comes from the referenced message. On ProcessEngine, it is an event-qualified trigger entry subject to the restrictions above; Durable persists a Wait occurrence.
  • intermediateCatchEvent with timerEventDefinition - A Durable Timer uses timeDuration for a relative delay or timeDate for an absolute wake time. Both accept a literal or a Java expression. timeCycle is unsupported.
  • serviceTask - Service task. Requires exactly one cf:action; action mappings are nested in cf:action, not attached to the task.
  • scriptTask - Script task. Requires scriptFormat and nonblank standard <script> content; mapped cf:input/cf:output elements are placed in the task’s extensionElements.
  • receiveTask - Requires messageRef, which must resolve to exactly one top-level message definition with a nonblank name. On ProcessEngine, it is a named entry subject to the trigger-entry restrictions above; on Durable it is an exact persisted Wait occurrence. It has no inAction/outAction hooks; model explicit tasks when work is required before or after the boundary.
  • exclusiveGateway - Exclusive gateway
  • parallelGateway - Parallel gateway
  • inclusiveGateway - Inclusive gateway

BPMN parallel splits and joins must satisfy the gateway topology rules. In particular, merge exclusive alternatives within a parallel branch before entering the parallel join.

  • subProcess - Embedded subprocess. Each subprocess must be a connected graph with exactly one start event and one end event. ProcessEngine trigger entries are supported only in the root process: a fresh invocation does not restore an embedded call stack. Durable persists the scope stack and supports Waits inside embedded scopes.
  • callActivity - Call activity. Requires calledElement and exactly one of cf:classpath or cf:version; mapped cf:input/cf:output elements are placed in the activity’s extensionElements, and return mappings must name target process variables.

Workbench: The BPMN designer preserves the full subProcess hierarchy, including nested nodes and transitions, when converting between visual editing and XML. The browser simulator cannot execute embedded subprocesses. Preview on a Server configured for the appropriate engine to check their execution behavior.

Surface Supported scope Boundary
Designer editing and XML export Supported TBBPM/BPMN models, including Durable constructs Editing does not grant execution support
Designer validation Local model and topology checks Server strict preflight determines whether publication can proceed
Server preflight and publication Definitions executable by the explicitly configured PROCESS or DURABLE target Native Durable preparation checks the full dependency graph without creating Runs
PROCESS preview and synchronous execution ProcessEngine invocations Preview additionally requires the trusted-draft policy to be enabled
Server asynchronous invocation Persist and retry a complete ProcessEngine call No Durable Run, Wait, or continuation is created
DURABLE execution and operations Create, inspect, and control Runs; resolve uncertain Effects Result reads and operator commands are disabled separately by default
DURABLE draft preview Real Runs on a physically isolated PREVIEW host Production rejects inline preview; expiry requests cooperative cancellation

A local validation pass is not a promise that publication will succeed. Publication failures retain the Server’s preflight diagnostics. Configure the host using Durable Workbench; application integration remains available through the Durable guide.

  • message - Message definition metadata. It can be parsed and preserved on the BPMN model, but it is not a standalone executable node.
  • standardLoopCharacteristics - Executes a conditional or bounded standard loop. loopMaximum, when present, is an integer from 1 through 2147483647; at least loopCondition or loopMaximum is required.
  • multiInstanceLoopCharacteristics - Iterates over cf:collection sequentially or in parallel. Parallel mode is Durable-only and requires a List-compatible input. In either mode, set both cf:target and cf:source to collect ordered results; the two attributes must appear together. Sequential results are written back when the loop exits. Generated local variable names must be valid Java identifiers, and cf:itemType must be a valid Java class name.

Executable BPMN requires a nonblank targetNamespace, one process with isExecutable="true", globally unique ids, and only supported attributes and extension data. Unknown executable data fails parsing or preflight. The BPMN process id is its CompileFlow process code and must exactly match the code carried by ProcessDefinition. The complete cf: syntax and ownership rules are defined by the BPMN Extension Specification.

The following BPMN 2.0 elements are outside CompileFlow’s supported XML profile. Definitions containing them fail parsing or preflight. Where an application supplies similar business behavior, model the integration using a supported task or Wait boundary.

CompileFlow does not implement the task and event semantics of these elements:

  • userTask — Use an application-owned task service for assignment, authorization, and completion. Integrate it through a Durable Wait, or use a top-level Wait and ordinary trigger when a fresh invocation is the intended contract.
  • manualTask — Work performed outside the engine has no native task node or completion lifecycle in CompileFlow.
  • businessRuleTask — Native rule-task semantics are unsupported. Use a serviceTask with a class action to call a Java rule implementation or integrate an external decision service.
  • sendTask — Requires a messaging system with send/receive semantics. Use serviceTask instead.
  • boundaryEvent — Activity-attached error, compensation, and timer behavior is unsupported.
  • intermediateThrowEvent — Intermediate event emission is unsupported.
  • signal — Signal broadcast and subscriptions are unsupported.
  • Event definitions (cancelEventDefinition, compensateEventDefinition, conditionalEventDefinition, errorEventDefinition, escalationEventDefinition, linkEventDefinition, signalEventDefinition, terminateEventDefinition) — These event semantics are unsupported.

CompileFlow executes single-process flows; collaboration/choreography elements are out of scope:

  • choreography, choreographyTask, subChoreography
  • callConversation, conversation, subConversation
  • globalBusinessRuleTask, globalConversation, globalManualTask, globalScriptTask, globalUserTask
  • partnerEntity, partnerRole, participantAssociation, participantMultiplicity

The ProcessEngine runtime keeps invocation state in memory, and the Durable Store persists only CompileFlow’s own execution records. Neither engine implements BPMN data-store or resource-assignment behavior; the application manages those features:

  • dataStore, dataStoreReference, dataAssociation, dataInputAssociation
  • loopDataInputRef, loopDataOutputRef
  • resource, resourceRole, potentialOwner, performer, humanPerformer
  • assignment, resourceParameter, resourceParameterBinding, resourceAssignmentExpression
  • transaction — BPMN transaction and compensation semantics are unsupported. A service may use Spring @Transactional for its own database work; that does not make the whole flow a transaction.
  • complexGateway — The element’s event-condition behavior is unsupported.
  • eventBasedGateway — Waiting for competing events to select a path is unsupported.
  • group, textAnnotation, association — Diagram-only elements outside the supported XML profile.
  • auditing, monitoring — Use CompileFlow events, metrics, and application-owned observability.
  • category, categoryValue — Diagram grouping; no runtime effect.
  • correlationProperty, correlationSubscription, correlationKey — BPMN message-correlation metadata is unsupported; Durable completion identifies an exact Wait through its token.
  • error, escalation, itemDefinition, interface, operation, ioParameter, inputSet, outputSet, inputOutputSpecification, inputOutputBinding — Metadata for execution semantics CompileFlow does not implement.
  • lane, laneSet — Lane-based process organization is outside the supported XML profile.
  • multiInstanceFlowCondition — Multi-instance is handled via multiInstanceLoopCharacteristics.
  • complexBehaviorDefinition — The element’s behavior-monitoring semantics are unsupported.
  • endPoint, import, relationship, rendering — Schema-level metadata with no runtime effect.

An application task system can own task state, identity, and authorization, then invoke a top-level waitTask entry with all the state needed by the remaining flow. engine.trigger(definition, ProcessTrigger.at("approval"), approvalData) starts a fresh invocation; it does not require a preceding engine execution or resume a stored instance. An event-qualified entry additionally checks ProcessTrigger.on(nodeId, event) against its declared event. Use an unbounded Wait without Durable output mappings or native result projections for this ordinary execution contract.

For a persisted Run, model the human step as a waitTask and explicitly declare its reply:

<var name="approved" dataType="java.lang.Boolean" inOutType="inner"/>
<waitTask id="approval" name="Wait for Approval">
<output source="approved" target="approved"/>
<transition to="afterApproval"/>
</waitTask>

The Durable kernel commits the Wait and its WAIT_COMMITTED Outbox event. An external task service uses this event to create a task, deduplicating by eventId so repeated notifications do not create duplicate tasks. That service also manages assignment, forms, comments, and SLA policy.

When a reviewer submits a decision, the application verifies their identity and authorizes the task’s owning Run, then passes that Run ID and the Wait token to DurableProcessEngine.completeWait(...). The Run-bound overload rejects a token belonging to another Run; it does not replace the application’s authorization check.

durable.completeWait(runId, waitToken, Map.of("approved", true));

A waitToken allows its holder to complete one specific Wait and must be protected like a credential. CompileFlow provides human-in-the-loop orchestration, not an engine-native humanTask node or Human Task Management service.

ProcessEngine Runtime Scheduled Task Implementation

Section titled “ProcessEngine Runtime Scheduled Task Implementation”

To start a ProcessEngine invocation on a schedule, call it from the application’s scheduler:

@Scheduled(fixedDelayString = "${jobs.scheduled-flow.delay:PT1M}")
public void scheduledTask() {
engine.execute(ProcessDefinition.classpath(ProcessModelType.TBBPM, "scheduled.flow", "flows/scheduled.flow.bpm"), Map.of()).orElseThrow();
}

For a persisted delay within one Durable Run, use timerTask. The scheduler example above starts a separate invocation each time it runs.

Fixed delay schedules the next execution of this task after the preceding invocation returns. If each scheduled run must execute only once across a distributed deployment, the application must select one caller or handle duplicate calls idempotently.

Use this page and the format specifications to check supported elements. To investigate how they are implemented, start with the classes below. These are internal classes, not public APIs:

Parser presence alone is not enough. Some elements, such as BPMN message and loop characteristics, are metadata or wrappers rather than standalone runtime nodes. DurableMachineLowerer lowers Durable-only semantics to the persisted state machine; they do not use the ProcessEngine runtime.