Marcin Sanecki
Marcin Sanecki

Reputation: 1334

Many inputs for activity node vs merge node

What is the difference between joining n activities with one activity and joining n activities with merge node and then the merge node with one activity.

Upvotes: 4

Views: 4417

Answers (2)

Randula Koralage
Randula Koralage

Reputation: 338

Merge Node enter image description here

This brings multiple alternate flows together .
If two or more inflows are received by merge symbol, the outflow executed.

Join Node enter image description here

This synchronizes two or more inflows and produce a single flow.
Outflow from a join cannot be executed until all inflows have been received.

Upvotes: 1

Javier
Javier

Reputation: 12398

As I understand the UML specification:

A merge node is a control node that brings together multiple alternate flows. It is not used to synchronize concurrent flows but to accept one among several alternate flows. All tokens offered on incoming edges are offered to the outgoing edge. There is no synchronization of flows or joining of tokens.

On the other hand,

... an action can only begin execution when it has been offered control tokens on all incoming control flows and all its input pins have been offered object tokens sufficient for their multiplicity. The action begins execution by accepting all the offers of control and object tokens allowed by input pin multiplicity.

Upvotes: 4

Related Questions