This is an automated email from the ASF dual-hosted git repository. zhongjiajie pushed a commit to branch 3.0.0-beta-prepare in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git
commit 665e62af44b9457104cc871cbdfa35beeb3fd28f Author: QuakeWang <[email protected]> AuthorDate: Thu May 12 18:23:43 2022 +0800 [doc] Add example and notice about task type Dependent (#10001) Co-authored-by: Jiajie Zhong <[email protected]> (cherry picked from commit 0fe75482a21c56980f1c7f503bb75eaefb6417b3) --- docs/docs/en/guide/task/dependent.md | 48 ++++++++++++++++++------------ docs/docs/zh/guide/task/dependent.md | 49 +++++++++++++++++++------------ docs/img/depend-node-en.png | Bin 496668 -> 0 bytes docs/img/depend-node.png | Bin 123401 -> 0 bytes docs/img/depend-node1-en.png | Bin 516594 -> 0 bytes docs/img/depend-node2.png | Bin 120491 -> 0 bytes docs/img/depend-node3-en.png | Bin 479533 -> 0 bytes docs/img/depend-node3.png | Bin 140998 -> 0 bytes docs/img/dependent-nodes-en.png | Bin 95552 -> 0 bytes docs/img/dependent_edit.png | Bin 18061 -> 0 bytes docs/img/tasks/demo/dependent_task01.png | Bin 0 -> 159694 bytes docs/img/tasks/demo/dependent_task02.png | Bin 0 -> 159538 bytes docs/img/tasks/demo/dependent_task03.png | Bin 0 -> 164972 bytes docs/img/tasks/icons/dependent.png | Bin 0 -> 743 bytes docs/img/tasks/icons/python.png | Bin 34066 -> 1618 bytes 15 files changed, 61 insertions(+), 36 deletions(-) diff --git a/docs/docs/en/guide/task/dependent.md b/docs/docs/en/guide/task/dependent.md index ff86207451..1cbf354fd4 100644 --- a/docs/docs/en/guide/task/dependent.md +++ b/docs/docs/en/guide/task/dependent.md @@ -1,27 +1,39 @@ -# Dependent Node +# Dependent -- Dependent nodes are **dependency check nodes**. For example, process A depends on the successful execution of process B from yesterday, and the dependent node will check whether process B run successful yesterday. +## Overview -> Drag from the toolbar  task node to the canvas, as shown in the figure below: +Dependent nodes are **dependency check nodes**. For example, process A depends on the successful execution of process B from yesterday, and the dependent node will check whether process B run successful yesterday. -<p align="center"> - <img src="/img/dependent-nodes-en.png" width="80%" /> - </p> -> The dependent node provides a logical judgment function, such as checking whether the B process was successful yesterday, or whether the C process was executed successfully. +## Create Task - <p align="center"> - <img src="/img/depend-node-en.png" width="80%" /> - </p> +- Click `Project -> Management-Project -> Name-Workflow Definition`, and click the `Create Workflow` button to enter the DAG editing page. +- Drag from the toolbar <img src="/img/tasks/icons/dependent.png" width="15"/> task node to canvas. -> For example, process A is a weekly report task, processes B and C are daily tasks, and task A requires tasks B and C to be successfully executed every day of the last week, as shown in the figure: +## Task Parameter - <p align="center"> - <img src="/img/depend-node1-en.png" width="80%" /> - </p> +- **Node name**: The node name in a workflow definition is unique. +- **Run flag**: Identifies whether this node schedules normally, if it does not need to execute, select the `prohibition execution`. +- **Descriptive information**: Describe the function of the node. +- **Task priority**: When the number of worker threads is insufficient, execute in the order of priority from high to low, and tasks with the same priority will execute in a first-in first-out order. +- **Worker grouping**: Assign tasks to the machines of the worker group to execute. If `Default` is selected, randomly select a worker machine for execution. +- **Environment Name**: Configure the environment name in which run the script. +- **Times of failed retry attempts**: The number of times the task failed to resubmit. +- **Failed retry interval**: The time interval (unit minute) for resubmitting the task after a failed task. +- **Delayed execution time**: The time (unit minute) that a task delays in execution. -> If the weekly report A also needs to be executed successfully last Tuesday: +## Examples - <p align="center"> - <img src="/img/depend-node3-en.png" width="80%" /> - </p> \ No newline at end of file +The Dependent node provides a logical judgment function, which can detect the execution of the dependent node according to the logic. + +For example, process A is a weekly task, processes B and C are daily tasks, and task A requires tasks B and C to be successfully executed every day of the last week. + + + +And another example is that process A is a weekly report task, processes B and C are daily tasks, and task A requires tasks B or C to be successfully executed every day of the last week: + + + +If the weekly report A also needs to be executed successfully last Tuesday: + + diff --git a/docs/docs/zh/guide/task/dependent.md b/docs/docs/zh/guide/task/dependent.md index abdc0435c6..b3fbd91f8d 100644 --- a/docs/docs/zh/guide/task/dependent.md +++ b/docs/docs/zh/guide/task/dependent.md @@ -1,27 +1,40 @@ -# 依赖节点 +# Dependent 节点 -- 依赖节点,就是**依赖检查节点**。比如A流程依赖昨天的B流程执行成功,依赖节点会去检查B流程在昨天是否有执行成功的实例。 +## 综述 -> 拖动工具栏中的任务节点到画板中,如下图所示: +Dependent 节点,就是**依赖检查节点**。比如 A 流程依赖昨天的 B 流程执行成功,依赖节点会去检查 B 流程在昨天是否有执行成功的实例。 -<p align="center"> - <img src="/img/dependent_edit.png" width="80%" /> - </p> +## 创建任务 - > 依赖节点提供了逻辑判断功能,比如检查昨天的B流程是否成功,或者C流程是否执行成功。 +- 点击项目管理 -> 项目名称 -> 工作流定义,点击“创建工作流”按钮,进入 DAG 编辑页面; +- 拖动工具栏的<img src="/img/tasks/icons/dependent.png" width="15"/> 任务节点到画板中。 - <p align="center"> - <img src="/img/depend-node.png" width="80%" /> - </p> +## 任务参数 - > 例如,A流程为周报任务,B、C流程为天任务,A任务需要B、C任务在上周的每一天都执行成功,如图示: +- 节点名称:设置任务节点的名称。一个工作流定义中的节点名称是唯一的。 +- 运行标志:标识这个结点是否能正常调度,如果不需要执行,可以打开禁止执行开关。 +- 描述:描述该节点的功能。 +- 任务优先级:worker 线程数不足时,根据优先级从高到低依次执行,优先级一样时根据先进先出原则执行。 +- Worker 分组:任务分配给 worker 组的机器执行,选择 Default ,会随机选择一台 worker 机执行。 +- 环境名称:配置运行脚本的环境。 +- 失败重试次数:任务失败重新提交的次数。 +- 失败重试间隔:任务失败重新提交任务的时间间隔,以分为单位。 +- 超时警告:勾选超时警告、超时失败,当任务超过“超时时长”后,会发送告警邮件并且任务执行失败。 +- 添加依赖:需要判断的依赖任务,可以是某一个项目中的工作流具体的任务执行情况。 +- 前置任务:选择当前任务的前置任务,会将被选择的前置任务设置为当前任务的上游。 - <p align="center"> - <img src="/img/depend-node2.png" width="80%" /> - </p> +## 任务样例 - > 假如,周报A同时还需要自身在上周二执行成功: +Dependent 节点提供了逻辑判断功能,可以按照逻辑来检测所依赖节点的执行情况。 - <p align="center"> - <img src="/img/depend-node3.png" width="80%" /> - </p> \ No newline at end of file +例如,A 流程为周报任务,B、C 流程为天任务,A 任务需要 B、C 任务在上周的每一天都执行成功,如图示: + + + +例如,A 流程为周报任务,B、C 流程为天任务,A 任务需要 B 或 C 任务在上周的每一天都执行成功,如图示: + + + +假如,周报 A 同时还需要自身在上周二执行成功: + + diff --git a/docs/img/depend-node-en.png b/docs/img/depend-node-en.png deleted file mode 100644 index d1711d7c8b..0000000000 Binary files a/docs/img/depend-node-en.png and /dev/null differ diff --git a/docs/img/depend-node.png b/docs/img/depend-node.png deleted file mode 100644 index 5ea74bfccf..0000000000 Binary files a/docs/img/depend-node.png and /dev/null differ diff --git a/docs/img/depend-node1-en.png b/docs/img/depend-node1-en.png deleted file mode 100644 index 62314cb979..0000000000 Binary files a/docs/img/depend-node1-en.png and /dev/null differ diff --git a/docs/img/depend-node2.png b/docs/img/depend-node2.png deleted file mode 100644 index 7fcb1434df..0000000000 Binary files a/docs/img/depend-node2.png and /dev/null differ diff --git a/docs/img/depend-node3-en.png b/docs/img/depend-node3-en.png deleted file mode 100644 index 18ad849a6c..0000000000 Binary files a/docs/img/depend-node3-en.png and /dev/null differ diff --git a/docs/img/depend-node3.png b/docs/img/depend-node3.png deleted file mode 100644 index 88dceb2684..0000000000 Binary files a/docs/img/depend-node3.png and /dev/null differ diff --git a/docs/img/dependent-nodes-en.png b/docs/img/dependent-nodes-en.png deleted file mode 100644 index 152a55ea31..0000000000 Binary files a/docs/img/dependent-nodes-en.png and /dev/null differ diff --git a/docs/img/dependent_edit.png b/docs/img/dependent_edit.png deleted file mode 100644 index 1dac57468b..0000000000 Binary files a/docs/img/dependent_edit.png and /dev/null differ diff --git a/docs/img/tasks/demo/dependent_task01.png b/docs/img/tasks/demo/dependent_task01.png new file mode 100644 index 0000000000..68a140a15d Binary files /dev/null and b/docs/img/tasks/demo/dependent_task01.png differ diff --git a/docs/img/tasks/demo/dependent_task02.png b/docs/img/tasks/demo/dependent_task02.png new file mode 100644 index 0000000000..3f2afa4158 Binary files /dev/null and b/docs/img/tasks/demo/dependent_task02.png differ diff --git a/docs/img/tasks/demo/dependent_task03.png b/docs/img/tasks/demo/dependent_task03.png new file mode 100644 index 0000000000..1bc2f50aac Binary files /dev/null and b/docs/img/tasks/demo/dependent_task03.png differ diff --git a/docs/img/tasks/icons/dependent.png b/docs/img/tasks/icons/dependent.png new file mode 100644 index 0000000000..3f0b732c40 Binary files /dev/null and b/docs/img/tasks/icons/dependent.png differ diff --git a/docs/img/tasks/icons/python.png b/docs/img/tasks/icons/python.png index 9775b28be2..8bc4d516aa 100644 Binary files a/docs/img/tasks/icons/python.png and b/docs/img/tasks/icons/python.png differ
