facts verified 2026-11-12 · Microsoft Learn · Airflow Azure provider 15.3.1
A master pipeline is an Azure Data Factory pipeline whose job is to run other pipelines, in order, through Execute Pipeline activities. Apache Airflow is an open-source scheduler that can run those same ADF pipelines as tasks in a Python DAG. Both decide what runs when. They differ on where the dependencies live, how a failure recovers, and who can maintain the result. Moving a master pipeline to Airflow gives you code review, automatic task retries, and one place to see the whole schedule. It also gives you a second system to run, and Airflow's retry of an ADF task starts a new pipeline run from the first activity, so the recovery problem only shrinks as far as you split the work into smaller tasks. For teams that already run Airflow beside Data Factory, the deciding question is how big each task should be.
A disclosure before the details. ETLMaestro sells a metadata-driven orchestration layer for Azure Data Factory and Microsoft Fabric, which is a third answer to this question, so we are not neutral. Every claim about ADF and Airflow below links to Microsoft's documentation or the Airflow provider's own code, and the section on our product is labeled.
This article covers one design: Airflow running the Data Factory pipelines that a master pipeline runs today. For how the two tools compare in general, on authoring, hosting, cost, and limits, read Airflow vs Azure Data Factory.
Master pipeline vs Airflow at a glance
The master pipeline keeps orchestration inside Data Factory, where it is free to run and visual to read until it grows. Airflow moves orchestration into Python, where it is reviewable and retries itself, at the price of an extra platform and a split view of every failure. The table compares them on the questions that come up when a master pipeline starts to hurt.
| Master pipeline (ADF) | Airflow over ADF | |
|---|---|---|
| Where dependencies live | Activity dependencies drawn on the ADF canvas, stored as pipeline JSON | A Python DAG file, in source control |
| Scheduling | ADF triggers on the master pipeline | The Airflow scheduler; ADF triggers removed |
| Automatic retry | Per activity, through retry policies on the activities that have one | Per task, through retries and retry_delay |
| Recovery after a failed run | Manual "Rerun from failed activity" in ADF Monitor, which skips succeeded work | Task retry or clear, which starts a new ADF run of that task's pipeline from its first activity |
| Finding the error | ADF Monitor, drilling through child runs | Airflow shows the failed task; the activity error is in ADF Monitor |
| Published limits | 120 activities per pipeline; ForEach can't nest and runs at most 50 in parallel | No per-DAG cap; limits come from how you size the scheduler and workers |
| Who can change it | Anyone who works in ADF Studio | Python developers, plus ADF developers for the pipelines underneath |
| Orchestration cost | $1 per 1,000 activity runs, Execute Pipeline included | The same ADF runs, plus about $240 to $850 a month self-hosted or from $255 managed |
What is a master pipeline in Azure Data Factory?
A master pipeline is a top-level ADF pipeline that orchestrates instead of moving data. Its activities are mostly Execute Pipeline calls, each one waiting for a child pipeline to finish before the next starts, and the children often call children of their own. Teams build it because ADF offers no other place to say "run B after A" across pipelines, and because a ForEach can't contain another ForEach, which Microsoft's own workaround solves with a child pipeline. Each Execute Pipeline activity looks like this in the pipeline JSON:
{
"name": "Execute PL_Transform",
"type": "ExecutePipeline",
"dependsOn": [
{ "activity": "Execute PL_Stage",
"dependencyConditions": ["Succeeded"] }
],
"typeProperties": {
"pipeline": { "referenceName": "PL_Transform",
"type": "PipelineReference" },
"waitOnCompletion": true
}
} Nothing about that is wrong. The trouble is accumulation. Three years of reasonable additions produce a tree only one engineer can read, with a failure path nobody has documented. We wrote up that pattern, and what it costs, as the master pipeline problem. This article picks up where teams usually go next, which is asking whether Airflow should take over.
What changes when Airflow orchestrates Data Factory?
The schedule and the dependencies move into a Python file, and the ADF
pipelines underneath stay where they are. Airflow's Microsoft Azure
provider ships an AzureDataFactoryRunPipelineOperator that
starts an ADF pipeline run and waits for it to finish, so each Execute
Pipeline activity in the master pipeline becomes an Airflow task, and
each arrow becomes a >>. Microsoft documents the same
pattern for the Apache Airflow job in Fabric, with a service principal
granted Contributor on the data factory. The master pipeline itself
goes away, or stays as one of the tasks.
Here is the master pipeline from the diagram as a DAG. Two staging pipelines run in parallel, then the transform, then the publish, every night at 2 a.m., with two retries per task.
from datetime import datetime, timedelta
from airflow import DAG
from airflow.providers.microsoft.azure.operators.data_factory import (
AzureDataFactoryRunPipelineOperator,
)
with DAG(
dag_id="nightly_load",
schedule="0 2 * * *",
start_date=datetime(2026, 10, 1),
catchup=False,
default_args={
"azure_data_factory_conn_id": "adf_prod",
"resource_group_name": "rg-data",
"factory_name": "adf-prod",
"retries": 2,
"retry_delay": timedelta(minutes=10),
"deferrable": True,
},
):
stage_sales = AzureDataFactoryRunPipelineOperator(
task_id="stage_sales", pipeline_name="PL_Stage_Sales")
stage_finance = AzureDataFactoryRunPipelineOperator(
task_id="stage_finance", pipeline_name="PL_Stage_Finance")
transform = AzureDataFactoryRunPipelineOperator(
task_id="transform", pipeline_name="PL_Transform")
publish = AzureDataFactoryRunPipelineOperator(
task_id="publish", pipeline_name="PL_Publish")
[stage_sales, stage_finance] >> transform >> publish
That file is shorter than the JSON behind most master pipelines, it
goes through pull requests, and the Airflow graph view draws the whole
night on one screen. Those are the reasons teams make the move. Setting
deferrable hands the waiting to Airflow's triggerer, so a
worker slot isn't held for the hours a load can take.
What happens when step 47 fails?
In a master pipeline, ADF retries the failed activity if its retry policy allows, and after that a person reruns the master pipeline from the failed activity in ADF Monitor. That rerun is smarter than its reputation: per Microsoft's rerun rules, child pipelines are triggered again and their succeeded activities can be skipped. In Airflow, the task retries on its own. But the operator starts each attempt by calling Data Factory's Create Run API without a reference to the failed run, so the retry is a brand-new pipeline run that starts at the first activity. If one Airflow task runs the whole master pipeline, every automatic retry reruns the whole night.
The operator does accept ADF's recovery parameters,
reference_pipeline_run_id, is_recovery, and
start_from_failure, which map to the same options the
Create Run API documents. They default to empty, though, and nothing
hands a retry the ID of the run that just failed. Using them on a retry
means writing your own logic to fetch that ID and pass it in. Few teams
do, so in practice the grain of recovery is the size of the task.
That makes task size the real design decision. One task per small pipeline keeps retries cheap and the graph honest. One task per large pipeline, or the master pipeline wrapped in a single task, gives you Airflow's scheduler with the master pipeline's recovery bill. Clearing a task in the Airflow UI with its downstream tasks selected reruns from that point, and the same rule applies: the cleared task's pipeline starts from its top.
Where do you look when it fails at 2 a.m.?
With a master pipeline, everything is in ADF Monitor. You open the failed run, find the Execute Pipeline activity that failed, open its child run, and repeat until you reach the activity with the error. With Airflow over ADF, the Airflow UI tells you which task failed and its log says the ADF pipeline run failed, with the run ID and a "Monitor Pipeline Run" link. The activity error itself is still in Data Factory, so whoever is on call needs access to both tools.
Neither path ends at a view the business can read. ADF Monitor keeps 45 days of run history and needs access to the factory. The Airflow UI needs an Airflow login. "Did last night's load finish?" still goes to an engineer in both cases, which is the visibility half of the master pipeline problem, and Airflow doesn't change it.
Who can maintain each one?
A master pipeline can be changed by anyone who works in ADF Studio, which is the point of a visual tool and also why it sprawls: nothing stops one more arrow. An Airflow DAG over ADF needs two skill sets, Python for the DAG and Data Factory for the pipelines it runs, and in most Azure data teams those aren't the same people. Code review makes the orchestration easier to audit. It doesn't remove the key-person risk if the one engineer who knows Airflow is also the one who wrote the DAG.
There is a real gain here, and it's worth stating. A DAG in source control has history, diffs, and reviewers, and a new engineer can read the dependencies in a few dozen lines instead of clicking through a canvas. If your team already writes Python and already runs Airflow for other work, that gain is close to free.
What does each cost to run?
Orchestration inside ADF is billed per activity run, $1 per 1,000 on the Azure integration runtime, and Execute Pipeline activities count like any other. A nightly master pipeline with 50 Execute Pipeline activities adds about 1,500 runs a month, or $1.50. Airflow over ADF keeps every ADF run charge, because the pipelines still run in ADF, and adds the Airflow platform: about $240 a month for small self-hosted production on Azure, about $850 for high availability on AKS, from about $255 on Astronomer's Astro, or about $657 to $1,314 for an always-on Fabric Airflow job pool, before the engineering time to operate it.
The line items behind those figures, and the hours, are in what Apache Airflow actually costs to run on Azure. They are US list prices, last checked on 2026-11-12, so check current rates before budgeting.
When is Airflow the right replacement for a master pipeline?
When your team already runs Airflow, writes Python every day, and orchestrates more than Data Factory, such as dbt, Databricks, or systems outside Azure. Then the master pipeline is one more workload joining a scheduler you already operate, the DAG can coordinate ADF with everything else, and the platform cost is already paid. Split the master pipeline into one task per child pipeline when you move it, so retries stay small.
Airflow is also the better fit when the estate is leaving Azure, or when workflows need to be generated from code. If Airflow would be new to you, the ways to run it on Azure, including the end of new Airflow instances in ADF on January 1, 2026, are in Apache Airflow on Azure: managed options and alternatives. Every comparison we publish is listed on one page.
When should you keep the master pipeline and fix it instead?
When Data Factory is the whole estate and is staying, and the people maintaining it build pipelines rather than write Python. In that case the pain behind the question is usually recovery, visibility, and one person holding the design, and Airflow adds a platform without fixing the first two. The fixes that do help are in ADF already: smaller child pipelines, retry policies on the activities that fail transiently, and "Rerun from failed activity" instead of rerunning from zero.
The step past that is moving the orchestration design out of the canvas and into a table: which pipelines run, in what order, with what parameters. Metadata-driven ETL in Azure Data Factory walks through the control-table pattern teams build for this.
Is there an option between the two?
Yes, and it's the one we sell, so weigh this section accordingly. ETLMaestro is a metadata-driven orchestration layer for Azure Data Factory and Microsoft Fabric. The schedule, the dependencies, and the phases live as rows in a database in your own subscription, and it runs the ADF pipelines and Fabric notebooks you already have. Runs execute in checkpointed phases, and a retry reruns only the processes that failed, automatically, so the master pipeline's recovery bill goes away without a second scheduler or a rewrite in Python.
Status lands in a Power BI report anyone with workspace access can read. It is not a replacement for Airflow, and if your team wants orchestration as Python code, Airflow is the better answer. Pricing is published, from $200 a month, with two months free. How ETLMaestro works follows a run from start to retry.
Questions teams ask about master pipelines and Airflow
Can Airflow trigger an Azure Data Factory pipeline?
Yes. The apache-airflow-providers-microsoft-azure package
includes AzureDataFactoryRunPipelineOperator, which starts a
pipeline run and, by default, waits for it to succeed. Microsoft's
tutorial for the Fabric Apache Airflow job uses the same provider, with
a service principal added as a Contributor on the data factory.
Does an Airflow retry rerun the whole ADF pipeline?
By default, yes. Each attempt calls Data Factory's Create Run API, which starts a new pipeline run from the first activity. Activities that succeeded in the failed attempt run again. Recovery mode exists in the API and the operator, but using it on a retry takes custom code to pass the failed run's ID.
Does "Rerun from failed activity" skip work inside child pipelines?
It can. Microsoft's rerun rules say an Execute Pipeline activity triggers the child pipeline again, but activities in the child may still be skipped based on the rerun rules. A person has to start the rerun from ADF Monitor or through the API, though. It doesn't happen on its own.
Should we migrate our master pipeline to Airflow?
If you already run Airflow and your team writes Python, moving the master pipeline into a DAG with one task per child pipeline is a reasonable step. If Airflow would be new, and the estate is ADF or Fabric and staying there, fix recovery and visibility first. You may find the scheduler was never the problem. The Master Pipeline Health Check scores which of those your estate needs.
Can Airflow orchestrate Fabric pipelines the same way?
Yes. The Apache Airflow job in Fabric can run Fabric items, including pipelines and notebooks, from a DAG, authenticating with a service principal or the workspace identity. As of 2026-11-12 it doesn't support private or virtual networks, and it bills against your Fabric capacity while its pool is up. Moving the pipelines themselves from ADF to Fabric is a separate decision, covered in Fabric Data Factory vs Azure Data Factory.
Sources and verification
Verified 2026-11-12. Operator behaviour was read from the source of
apache-airflow-providers-microsoft-azure 15.3.1. Cost
figures were last checked on 2026-11-12 and are sourced line by
line on the linked cost article. This page is reviewed quarterly.
- Microsoft Learn: Execute Pipeline activity in Azure Data Factory (waitOnCompletion defaults to true; Invoke Pipeline is the Fabric equivalent)
- Microsoft Learn: Visually monitor Azure Data Factory (rerun rules for container and Execute Pipeline activities; Rerun from failed activity)
- Microsoft Learn: Data Factory REST API, Pipelines Create Run (referencePipelineRunId, isRecovery, startActivityName, startFromFailure)
- Microsoft Learn: Pipelines and activities (activity dependencies; 120 activities per pipeline)
- Microsoft Learn: ForEach activity limitations (no nested ForEach; batchCount up to 50; child pipeline workaround)
- Microsoft Learn: Monitor Data Factory programmatically (45-day pipeline-run retention)
- Microsoft Learn: Azure Data Factory limits
- Azure pricing: Data Factory pipeline orchestration and execution ($1 per 1,000 activity runs, Azure integration runtime)
- Apache Airflow: Azure Data Factory operators (AzureDataFactoryRunPipelineOperator, deferrable mode, run status sensor)
- PyPI: apache-airflow-providers-microsoft-azure (operator source, version 15.3.1)
- Apache Airflow docs: Tasks (retries and the up_for_retry state)
- Apache Airflow docs: Dag Runs (re-running tasks by clearing them, with upstream, downstream, and failed options)
- Microsoft Learn: Orchestrate an Azure Data Factory pipeline with Apache Airflow jobs (service principal as Contributor on the factory)
- Microsoft Learn: Workspace identity for Apache Airflow jobs (running Fabric pipelines and notebooks)
- Microsoft Learn: What is an Apache Airflow job? (no private or virtual network support)