You orchestrate ETL pipelines by using Cloud Composer. One of the tasks in the Apache Airflow directed acyclic graph (DAG) relies on a third-party service. You want to be notified when the task does not succeed. What should you do?
A.
Assign a function with notification logic to the on_retry_callback parameter for the operator responsible for the task at risk.
B.
Configure a Cloud Monitoring alert on the sla_missed metric associated with the task at risk to trigger a notification.
C.
Assign a function with notification logic to the on_failure_callback parameter tor the operator responsible for the task at risk.
D.
Assign a function with notification logic to the sla_miss_callback parameter for the operator responsible for the task at risk.
on_failure_callback is invoked when the task fails
https://airflow.apache.org/docs/apache-airflow/stable/administration-and-deployment/logging-monitoring/callbacks.html
- The on_failure_callback is a function that gets called when a task fails.
- Assigning a function with notification logic to this parameter is a direct way to handle task failures.
- When the task fails, this function can trigger a notification, making it an appropriate solution for the need to be alerted on task failures.
Direct Trigger:
The on_failure_callback parameter is specifically designed to invoke a function when a task fails, ensuring immediate notification.
Customizable Logic:
You can tailor the notification function to send emails, create alerts, or integrate with other notification systems, providing flexibility.
upvoted 4 times
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
jonty4gcp
3 months, 1 week agoAnudeep58
6 months agoJyoGCP
9 months agodatapassionate
10 months, 2 weeks agoMatt_108
10 months, 2 weeks agoraaad
10 months, 3 weeks agoe70ea9e
11 months ago