4 Templating tasks using the Airflow context
This chapter covers
- Rendering variables at runtime with templating
- Master variable templating with the PythonOperator and across all other operators
- Rendering templated variables for debugging purposes
- Performing operations on external systems
In the previous chapters, we touched the surface of how DAGs and operators work together and how to schedule a workflow in Airflow. In this chapter, we look in-depth at what operators represent, what they are, how they function, and when and how they are executed. We also demonstrate how operators can be used to communicate with remote systems via hooks, which allows you to perform tasks such as loading data into a database, running a command in a remote environment, and performing workloads outside of Airflow.