Repository navigation
5.5.2.1.9. Join Node
A Join Node synchronizes incoming flows before allowing its outgoing flow to continue. In UML, the bar-shaped join waits for the required incoming control/object flows; it is distinct from a Merge Node, which passes alternative arrivals through without synchronization.
flowchart LR
start@{ shape: circle, label: " " }
start --> item(Load items)
start --> address(Validate address)
item --> sync
address --> sync
sync[ ]:::bar
sync --> ship(Dispatch order)
classDef bar fill:#000,stroke:#000
Mermaid approximation: this diagram shows the model's routing, not a complete UML Activity notation. Rounded boxes represent actions; edge labels identify token types or guards. The black rectangle approximates a UML fork/join bar; its exact proportions depend on Mermaid rendering.
.AddInitial(node => node
.AddControlFlow("LoadItems")
.AddControlFlow("ValidateAddress"))
.AddAction(
"LoadItems",
async c => c.OutputRange(await orders.LoadItemsAsync(orderId, c.CancellationToken)),
node => node.AddFlow<Item, JoinNode>())
.AddAction(
"ValidateAddress",
async c => c.Output(await addresses.ValidateAsync(orderId, c.CancellationToken)),
node => node.AddFlow<AddressCheck, JoinNode>())
.AddJoin(join => join
.AddFlow<Item>("DispatchOrder")
.AddFlow<AddressCheck>("DispatchOrder"))
.AddAction("DispatchOrder", async c =>
await shipping.DispatchAsync(
c.GetTokensOfType<Item>(),
c.GetTokensOfType<AddressCheck>().Single(),
c.CancellationToken))Configure each incoming flow explicitly so the Join receives the required arrivals. The Join forwards tokens onward; the target can read the input token types after synchronization. Do not substitute a Join where every arriving branch should proceed independently: use a Merge Node for that. See also Implicit Fork and Join.
Home page Support Code licensed under an MIT-style License. Documentation licensed under CC BY 4.0. © by Mikołaj Milewski, 2026