NOTE: The transition from 1.8.0 (or before) to 1.8.1 (or after) requires uninstalling Airflow before installing the new version. The package name was changed from airflow
to apache-airflow
as of version 1.8.1.
Airflow is a platform to programmatically author, schedule and monitor workflows.
When workflows are defined as code, they become more maintainable, versionable, testable, and collaborative.
Use Airflow to author workflows as directed acyclic graphs (DAGs) of tasks. The Airflow scheduler executes your tasks on an array of workers while following the specified dependencies. Rich command line utilities make performing complex surgeries on DAGs a snap. The rich user interface makes it easy to visualize pipelines running in production, monitor progress, and troubleshoot issues when needed.
Please visit the Airflow Platform documentation for help with installing Airflow, getting a quick start, or a more complete tutorial.
For further information, please visit the Airflow Wiki.
Airflow is not a data streaming solution. Tasks do not move data from one to the other (though tasks can exchange metadata!). Airflow is not in the Spark Streaming or Storm space, it is more comparable to Oozie or Azkaban.
Workflows are expected to be mostly static or slowly changing. You can think of the structure of the tasks in your workflow as slightly more dynamic than a database structure would be. Airflow workflows are expected to look similar from a run to the next, this allows for clarity around unit of work and continuity.
- Dynamic: Airflow pipelines are configuration as code (Python), allowing for dynamic pipeline generation. This allows for writing code that instantiates pipelines dynamically.
- Extensible: Easily define your own operators, executors and extend the library so that it fits the level of abstraction that suits your environment.
- Elegant: Airflow pipelines are lean and explicit. Parameterizing your scripts is built into the core of Airflow using the powerful Jinja templating engine.
- Scalable: Airflow has a modular architecture and uses a message queue to orchestrate an arbitrary number of workers. Airflow is ready to scale to infinity.
-
Tree View: Tree representation of a DAG that spans across time.
-
Graph View: Visualization of a DAG's dependencies and their current status for a specific run.
-
Task Duration: Total time spent on different tasks over time.
Airflow supports running CWL descriptor files in two following modes:
- Manual (user specifies CWL descriptor and input parameters files explicitly)
- Batch processing (user set the path to CWL descriptor and input parameters files)
This functionality is implemented within two additional packages cwl_runner
and cwl_dag
to support manual and batch processing correspondingly. Internally both of them call functions from cwltool
reference implementation to run each step of workflow separately. But the order of step running, transferring the data between steps and collecting results are implemented by means of Airflow.
To run some specific CWL descriptor file with an input parameters file airflow-cwl-runner
script should be used. It inherits all arguments from airflow backfill
command with the following additional ones.
Positional arguments:
workflow - path to CWL descriptor file
job - path to input parameters file
Optional arguments:
--outdir OUTDIR Output folder to save results
--tmp-folder TMP_FOLDER Temp folder to store intermediate data
between airflow tasks/steps execution
--tmpdir-prefix TMPDIR_PREFIX Path prefix for temporary directories
--tmp-outdir-prefix TMP_OUTDIR_PREFIX Path prefix for intermediate output directories
--quiet Print only workflow execution results
--ignore-def-outdir Disable default output directory to be set to
current directory. Use OUTPUT_FOLDER from
Airflow configuration file instead
Example:
airflow-cwl-runner --quiet workflow.cwl parameters.json
To process a group of input parameters files with correspondent CWL descriptor files using
airflow scheduler
some additional configuration should be added into airflow.cfg
file.
Update
[core]
dags_are_paused_at_creation = False
load_examples = False
Add
[biowardrobe]
cwl_jobs = absolute path to input parameter files folder. Required
cwl_workflows = absolute path to workflow descriptor files folder. Required
output_folder = absolute path to output results folder. Optional (default: current working directory)
tmp_folder = absolute path to temporary calculation folder. Optional (default: random generated in OS temp folder)
max_jobs_to_run = maximum number of jobs to be processed at the same time, int. Optional (default: 1)
log_level = log level, [CRITICAL, ERROR, WARNING, INFO, DEBUG, NOTSET]. Optional (default: INFO)
strict = enable strict validation, boolean. Optional (default: False)
To allow automatically fetch CWL descriptor file on the base of the input parameters file, the folowing naming rule should be implemented:
XXXXXXX.cwl - workflow descriptor name
XXXXXXX-id.json - input parameters files
where XXXXXXX, id - any allowed by OS set of symbols to define filename
To run airflow scheduler
with CWL support --subdir
parameter should point to folder with cwl_dag.py
file (which is by default in airflow.cwl_dag
package).
Airflow will automatically read input parameters files from cwl_jobs folder,
search for correspondent CWL descriptor files in cwl_workflows folder,
run it and put results in a subdirectory of output_folder
As the Airflow community grows, we'd like to keep track of who is using the platform. Please send a PR with your company name and @githubhandle if you may.
Committers:
- Refer to Committers
Currently officially using Airflow:
- Airbnb [@mistercrunch, @artwr]
- Agari [@r39132]
- allegro.pl [@kretes]
- AltX [@pedromduarte]
- Apigee [@btallman]
- Astronomer [@schnie]
- Auth0 [@sicarul]
- BandwidthX [@dineshdsharma]
- Bellhops
- BlaBlaCar [@puckel & @wmorin]
- Bloc [@dpaola2]
- BlueApron [@jasonjho & @matthewdavidhauser]
- Blue Yonder [@blue-yonder]
- Celect [@superdosh & @chadcelect]
- Change.org [@change, @vijaykramesh]
- Children's Hospital of Philadelphia Division of Genomic Diagnostics [@genomics-geek]
- City of San Diego [@MrMaksimize, @andrell81 & @arnaudvedy]
- Clairvoyant @shekharv
- Clover Health [@gwax & @vansivallab]
- Chartboost [@cgelman & @dclubb]
- Cotap [@maraca & @richardchew]
- Digital First Media [@duffn & @mschmo & @seanmuth]
- Easy Taxi [@caique-lima & @WesleyBatista]
- evo.company [@orhideous]
- FreshBooks [@DinoCow]
- Gentner Lab [@neuromusic]
- Glassdoor [@syvineckruyk]
- GovTech GDS [@chrissng & @datagovsg]
- Groupalia [@jesusfcr]
- Gusto [@frankhsu]
- Handshake [@mhickman]
- Handy [@marcintustin / @mtustin-handy]
- HBO[@yiwang]
- HelloFresh [@tammymendt & @davidsbatista & @iuriinedostup]
- Holimetrix [@thibault-ketterer]
- Hootsuite
- IFTTT [@apurvajoshi]
- iHeartRadio[@yiwang]
- ING
- Jampp
- Kiwi.com [@underyx]
- Kogan.com [@geeknam]
- Lemann Foundation [@fernandosjp]
- LendUp [@lendup]
- Letsbonus [@jesusfcr]
- liligo [@tromika]
- LingoChamp [@haitaoyao]
- Lucid [@jbrownlucid & @kkourtchikov]
- Lumos Labs [@rfroetscher & @zzztimbo]
- Lyft[@SaurabhBajaj]
- Madrone [@mbreining & @scotthb]
- Markovian [@al-xv, @skogsbaeck, @waltherg]
- Mercadoni [@demorenoc]
- MiNODES [@dice89, @diazcelsa]
- MFG Labs
- mytaxi [@mytaxi]
- Nerdwallet
- OfferUp
- OneFineStay [@slangwald]
- Open Knowledge International @vitorbaptista
- PayPal [@jhsenjaliya]
- Postmates [@syeoryn]
- Qubole [@msumit]
- Scaleway [@kdeldycke]
- Sense360 [@kamilmroczek]
- Shopkick [@shopkick]
- Sidecar [@getsidecar]
- SimilarWeb [@similarweb]
- SmartNews [@takus]
- Spotify [@znichols]
- Stackspace
- Stripe [@jbalogh]
- Thumbtack [@natekupp]
- T2 Systems [@unclaimedpants]
- Vente-Exclusive.com [@alexvanboxel]
- Vnomics [@lpalum]
- WePay [@criccomini & @mtagle]
- WeTransfer [@jochem]
- Whistle Labs [@ananya77041]
- WiseBanyan
- Wooga
- Xoom [@gepser & @omarvides]
- Yahoo!
- Zapier [@drknexus & @statwonk]
- Zendesk
- Zenly [@cerisier & @jbdalido]
- 99 [@fbenevides, @gustavoamigo & @mmmaia]