Commit 5823e9e6 authored by 唐香港's avatar 唐香港

Update airflow_heartbeat_detection.py

parent 125ba045
......@@ -13,7 +13,7 @@ DING_PATH = '/opt/bitnami/airflow/dags/*/script/ding.sh'
default_args = {
'owner': 'tangxianggang',
'depends_on_past': False,
'start_date': datetime.now() - timedelta(minutes=100),
'start_date': datetime.now() - timedelta(minutes=260),
'retries': 3,
'retry_delay': timedelta(seconds=5)
}
......@@ -21,14 +21,14 @@ default_args = {
dag = DAG(
dag_id='airflow_heartbeat_detection',
default_args=default_args,
schedule_interval=timedelta(minutes=50)
schedule_interval=timedelta(minutes=130)
)
def heartbeat_alarm(**kwargs):
logging.info('start heartbeat alarm')
title = 'airflow_heartbeat_detection'
msg = '\n- I am airflow, I will notify you once every 50 minutes.\
If I have not notified after 50 minutes, I have already hanged up.SOS...'
msg = '\n- I am airflow, I will notify you once every 130 minutes.\
If I have not notified after 130 minutes, I have already hanged up.SOS...'
message = '''I am airflow, I am still alive.!!!
\n#### DAG_ID: %s
\n#### TASKID: %s
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment