# Join - controllare perché diverso

## Description

The **Join** action is used to synchronize parallel branches in a workflow. It acts as a control point that **waits for all preceding parallel branches at the same level** to complete before continuing with the next action(s).

This eliminates the need to create separate child workflows solely for the purpose of joining and continuing execution after parallel tasks have completed.

## Usage

Traditionally in Apache Hop, if you wanted to run parts of a workflow in parallel and then continue with a sequential flow, you would isolate those parallel sections in a child workflow. This was necessary to prevent downstream actions from being executed prematurely.

With the new **Join** action, this workaround is no longer needed.

To use the Join action:

1. Configure your workflow with multiple outgoing hops from a single action.
2. Enable **parallel execution** on the outgoing hops you want to run in parallel.
3. Add the **Join** action at the point where all parallel branches converge.
4. Connect all parallel branches to the **Join** action with regular (non-parallel) hops.
5. Connect the **Join** action to the next action you want to execute **after all parallel tasks have finished**.

## Example Workflow Structure

When executed:

* The actions `pipeline-1`, `pipeline-2` and `pipeline-3` run in parallel.
* The `join` action waits until `pipeline-1`, `pipeline-2` and `pipeline-3` are finished.
* Once they complete, the workflow continues with final action `check-datasets`.

## Benefits

* **Simplifies parallel execution:** No need for a separate child workflow just to coordinate branches.
* **Improves readability:** Your parallel and sequential logic can be maintained in a single workflow.
* **Increases maintainability:** Fewer components and external dependencies (child workflows) to manage.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.primeur.com/data-shaper-1.21/knowing-the-data-shaper-designer/workflows/actions/join.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
