气流在1分钟后杀死了我的任务

问题描述:

我有一个非常简单的DAG,其中有两个任务,如下所示:

I have a very simple DAG with two tasks, like following:

default_args = {
    'owner': 'me',
    'start_date': dt.datetime.today(),
    'retries': 0,
    'retry_delay': dt.timedelta(minutes=1)
}

dag = DAG(
    'test DAG',
    default_args=default_args,
    schedule_interval=None
)

t0 = PythonOperator(
    task_id="task 1",
    python_callable=run_task_1,
    op_args=[arg_1, args_2, args_3],
    dag=dag,
    execution_timeout=dt.timedelta(minutes=60)
)

t1 = PythonOperator(
    task_id="task 2",
    python_callable=run_task_2,
    dag=dag,
    execution_timeout=dt.timedelta(minutes=60)
)

t1.set_upstream(t0)

但是,当我运行它时,我在日志中看到以下内容:

However, when I run it, I see the following in the logs:


[2017-10-17 16:18:35,519] {jobs.py:2083}信息-任务已退出,返回
返回码-9

[2017-10-17 16:18:35,519] {jobs.py:2083} INFO - Task exited with return code -9

没有任何其他有用的错误日志。有人看过吗?我是否错误地定义了DAG?任何帮助表示赞赏!

Without any other useful error logs. Anyone seen that before? Did I define my DAG wrongly? Any help appreciated!

如果任务容器没有足够的内存来执行任务,它将失败,错误代码为-9。
https://www.astronomer.io/guides/dag-best -practices /

If the task container doesn't have enough memory for a task, it will fail with error code -9. https://www.astronomer.io/guides/dag-best-practices/