lenboo edited a comment on issue #4325:
URL:
https://github.com/apache/incubator-dolphinscheduler/issues/4325#issuecomment-751673724
### 1. New tables and data structures, DB query interface (new structures do
not delete/modify existing workflow/task structures at this time):
- 1. New Workflow Definition Table: t_ds_Process_Definithon
```
|Column Name|Description|
| -------------------------------| ---------------- |
| id | Self-Increasing id |
| code | encoding (original name field)|
| version | version |
| description | description |
| project_code | project code |
| task_type | job type |
| task_params | Job Custom Parameters |
| run_flag | run flag |
| task_priority | job priority |
| worker_group | worker grouping |
| fail_retry_times | Number of failed retries |
| fail_retry_interval | failed retry interval |
| timeout_flag | timeout flag |
| timeout_notify_strategy | Timeout Notification Policy |
| timeout_duration | timeout length |
| create_time | creation time |
| update_time | modification time |
```
- 2. Workflow Job Relationships Table: t_ds_Process_Task_Relation
```
| Column Name | Description |
| ----------------------- | ------------------------- ------------- |
| id | self incrementing ID |
| project_code | project code |
| process_definition_code | Workflow coding |
| pre_project_code | pre-quoted project code |
| pre_task_code | pre-reference job code |
| condition_type | condition type 0: None 1: Judgment 2: Delayed |
| condition_params | condition parameters (json) |
| post_project_code | post reference project code |
| post_task_code | post reference job code |
| create_time | creation time |
| update_time | modification time |
```
- 3. Job Definition Table: t_ds_Task_Definithon
```
|Column Name|Description|
| ---- | ---- |
| id | Self-Increasing id |
| code | encoding (original name field)|
| version | version |
| description | description |
| project_code | project code |
| release_state | Publish status |
| user_id | Owner id |
| global_params | global parameters |
| flag | Is the process available: 0 not available, 1 available |
| receivers | recipients |
| warning_group_id | warning_group_id |
| timeout | timeout |
| tenant_id | Tenant id |
| locations | node coordinate information |
| create_time | creation time |
| update_time | modification time |
```
- 4. Workflow Definition Log Table: t_ds_Process_Definithon_Log
`Add operation type (add, modify, delete), operator, operation time based on
workflow definition table`
- 5. Workflow job relationship log table: t_ds_Process_Task_Relation_Log
`Add workflow version, operation type (add, modify, delete), operator,
operation time based on job relationship table`
- 6. Job Definition Log Table: t_ds_Task_Definithon_Log
`Add operation type (add, modify, delete), operator, operation time based on
job definition table`
- 7. Workflow Instance Table Modification: t_ds_Process_Instance
`Add Workflow Definition Version Number Field`
### 1. 新增表以及数据结构,db查询接口(新增结构暂时不要删除/修改现有的工作流/任务结构):
- 1. 新增工作流定义表:t_ds_process_definithon
```
| 列名 | 描述 |
| ---- | ---- |
| id | 自增ID |
| code | 编码(原name字段) |
| version | 版本 |
| description | 描述 |
| project_code | 项目编码 |
| release_state | 发布状态 |
| user_id | 所属用户ID |
| global_params | 全局参数 |
| flag | 流程是否可用:0 不可用,1 可用 |
|work_group_id|告警人分组id |
| timeout | 超时时间 |
| tenant_id | 租户ID |
| locations | 节点坐标信息 |
| create_time | 创建时间 |
| update_time | 修改时间 |
```
- 2. 工作流作业关系表:t_ds_process_task_relation
```
| 列名 | 描述 |
| ----------------------- | -------------------------------------- |
| id | 自增ID |
| project_code | 项目编码 |
| process_definition_code | 工作流编码 |
| pre_project_code | 前置引用项目编码 |
| pre_task_code | 前置引用作业编码 |
| condition_type | 条件类型 0:无 1:判断 2:延迟 |
| condition_params | 条件参数(json) |
| post_project_code | 后置引用项目编码 |
| post_task_code | 后置引用作业编码 |
| create_time | 创建时间 |
| update_time | 修改时间 |
```
- 3. 作业定义表:t_ds_task_definithon
```
| 列名 | 描述 |
| ---- | ---- |
| id | 自增id |
| code | 编码(原name字段) |
| version | 版本 |
| description | 描述 |
| project_code | 项目编码 |
| release_state | 发布状态 |
| user_id | 所属用户id |
| global_params | 全局参数 |
| flag | 流程是否可用:0 不可用,1 可用 |
| warning_group_id | 告警人 |
| timeout | 超时时间 |
| tenant_id | 租户id |
| locations | 节点坐标信息 |
| create_time | 创建时间 |
| update_time | 修改时间 |
```
- 4. 工作流定义日志表:t_ds_process_definithon_log
`工作流定义表基础上增加操作类型(新增、修改、删除)、操作人、操作时间`
- 5. 工作流作业关系日志表:t_ds_process_task_relation_log
`作业关系表基础上增加工作流版本、操作类型(新增、修改、删除)、操作人、操作时间`
- 6. 作业定义日志表:t_ds_task_definithon_log
`作业定义表基础上增加操作类型(新增、修改、删除)、操作人、操作时间`
- 7. 工作流实例表修改:t_ds_process_instance
`新增工作流定义版本号字段`
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]