I am trying to create multiple airflow tasks based on dag_run conf input. The conf would have an array of values and the each value needs to spawn a task. The task in turn needs to pass the value to its callable func. Something like this:
#create this task in a loop
task = PythonOperator(task_id="fetch_data", python_callable=fetch_data(value from array), retries=10)
Conf would have a value like:
{"fruits":["apple","kiwi","orange"]}
I think this can be accessed with:
kwargs['dag_run'].conf('fruits')
How do I access this value outside an operator and then create operators in a loop?