Your company runs a Cloud Composer environment (Apache Airflow 2). A BigQueryOperator task occasionally returns transient 500 errors that are cleared within a few minutes. Operations wants the pipeline to recover automatically by retrying the task up to three times, waiting five minutes between attempts, and increasing the waiting period for each subsequent failure to reduce load on BigQuery. Which set of Airflow task arguments in the Python task definition best meets these requirements?
Enable depends_on_past=True, limit max_active_runs to 1, and leave the default single retry.
Set retries=0 and retry_delay=timedelta(minutes=5) so the task fails fast and the DAG run can restart automatically.
Configure an on_failure_callback that triggers a new DAG run and set trigger_rule=all_failed instead of using retries.
Set retries=3, retry_delay=timedelta(minutes=5), and retry_exponential_backoff=True on the task.
Airflow controls automatic task retries through three arguments. Setting "retries" to 3 instructs Airflow to try the task three additional times after the first failure. "retry_delay=timedelta(minutes=5)" establishes an initial five-minute pause between the first and second attempt. Enabling "retry_exponential_backoff=True" causes Airflow to multiply the delay for each later retry (capped by default settings), so each successive wait grows longer. Together, these parameters provide self-healing for transient faults while backing off to protect the downstream service.
Incorrect answers:
Setting retries to 0 disables retries entirely.
depends_on_past and max_active_runs limit scheduling order but do not influence retries.
Using on_failure_callback to reschedule the DAG creates a new run rather than handling the failed task and does not enforce progressive delays.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
What is retry_exponential_backoff in Airflow?
Open an interactive chat with Bash
How does the retry_delay parameter affect retries in Airflow?
Open an interactive chat with Bash
What is the role of the retries argument in an Airflow task?
Open an interactive chat with Bash
What is Airflow's retry_exponential_backoff?
Open an interactive chat with Bash
How does retry_delay in Airflow work?
Open an interactive chat with Bash
What happens if retries are set to 0 in Airflow?
Open an interactive chat with Bash
GCP Professional Data Engineer
Maintaining and automating data workloads
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
Pass with Confidence.
IT & Cybersecurity Package
You have hit the limits of our free tier, become a Premium Member today for unlimited access.
Military, Healthcare worker, Gov. employee or Teacher? See if you qualify for a Community Discount.
Monthly
$19.99
$19.99/mo
Billed monthly, Cancel any time.
3 Month Pass
$44.99
$14.99/mo
One time purchase of $44.99, Does not auto-renew.
MOST POPULAR
Annual Pass
$119.99
$9.99/mo
One time purchase of $119.99, Does not auto-renew.
BEST DEAL
Lifetime Pass
$189.99
One time purchase, Good for life.
What You Get
All IT & Cybersecurity Package plans include the following perks and exams .