-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
70 changed files
with
1,042 additions
and
77 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
docs/04-features/01-catalog.md → docs/04-features/01-catalog/01-catalog.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
id: 'Catalog' | ||
id: 'catalog' | ||
title: 'Catalog' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"label": "Catalog Connector" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"label": "Catalog" | ||
} |
4 changes: 0 additions & 4 deletions
4
docs/04-features/02-data-quality/01-metric/01-metric-intro.md
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
49 changes: 49 additions & 0 deletions
49
docs/04-features/02-metric/01-single-table-metric/01-column-not-null.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
--- | ||
id: 'column-not-null' | ||
title: 'column_not_null' | ||
--- | ||
## 使用方法 | ||
- 点击创建规则作业,选择数据质量作业 | ||
- 进入作业页面选择 非空检查 规则 | ||
- 选择要检查的数据源信息 | ||
|
||
![自定义聚合SQL规则](/doc/image/metric_column_not_null.png) | ||
|
||
## 参数介绍 | ||
### Options | ||
|
||
| name | type | required | default value | | ||
|:----------------------------:|:------:|:----------:|:-------------:| | ||
| [database](#database-string) | string | yes | - | | ||
| [table](#table-string) | string | yes | - | | ||
| [column](#column-string) | string | yes | - | | ||
|
||
#### database [string] | ||
源表数据库名 | ||
#### table [string] | ||
源表数据库中的表名 | ||
#### column [string] | ||
要检查的列 | ||
|
||
### 配置文件例子 | ||
``` | ||
{ | ||
"metricType": "column_not_null", | ||
"metricParameter": { | ||
"database": "datavines", | ||
"table": "dv_catalog_entity_instance", | ||
"column": "type" | ||
} | ||
} | ||
``` | ||
|
||
## 使用案例 | ||
|
||
### 场景 | ||
... | ||
|
||
### 思路 | ||
... | ||
|
||
### 步骤 | ||
... |
50 changes: 50 additions & 0 deletions
50
docs/04-features/02-metric/01-single-table-metric/02-custom_aggregate_sql.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
--- | ||
id: 'custom-aggregate-sql' | ||
title: 'custom_aggregate_sql' | ||
--- | ||
|
||
## 使用方法 | ||
- 点击创建规则作业,选择数据质量作业 | ||
- 进入作业页面选择 自定义聚合SQL 规则 | ||
- 选择要检查的数据源信息,编写自定义聚合 SQL 语句 | ||
|
||
![自定义聚合SQL规则](/doc/image/metric_custom_aggregate_sql.png) | ||
|
||
## 参数介绍 | ||
### Options | ||
|
||
| name | type | required | default value | | ||
|:---------------------------------------------------------------:|:------:|:----------:|:-------------:| | ||
| [database](#database-string) | string | yes | - | | ||
| [table](#table-string) | string | yes | - | | ||
| [actual_aggregate_sql](#actual_execute_sql-string) | string | yes | - | | ||
|
||
#### database [string] | ||
源表数据库名 | ||
#### table [string] | ||
源表数据库中的表名 | ||
#### actual_aggregate_sql [string] | ||
自定义聚合SQL,注意 as 后面的别名一定要是 **actual_value**,否则统计会出错。 | ||
|
||
### 配置文件例子 | ||
``` | ||
{ | ||
"metricType": "custom_aggregate_sql", | ||
"metricParameter": { | ||
"database": "datavines", | ||
"table": "dv_actual_values", | ||
"actual_aggregate_sql": "select count(1) as actual_value from ${table}" | ||
} | ||
} | ||
``` | ||
|
||
## 使用案例 | ||
|
||
### 场景 | ||
... | ||
|
||
### 思路 | ||
... | ||
|
||
### 步骤 | ||
... |
3 changes: 3 additions & 0 deletions
3
docs/04-features/02-metric/01-single-table-metric/_category_.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"label": "Single Table Metric" | ||
} |
86 changes: 86 additions & 0 deletions
86
.../04-features/02-metric/02-multi-table-metric/01-multi-table-value-comparison.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
--- | ||
id: 'multi-table-value-comparison' | ||
title: 'multi_table_value_comparison' | ||
--- | ||
|
||
## 使用方法 | ||
- 点击创建规则作业,选择数据比对作业 | ||
- 进入作业页面选择 两表值比对 规则 | ||
- 进行源表和目标表的配置信息,编写各自的检查SQL语句 | ||
|
||
![两表值比对规则](/doc/image/metric_multi_table_value_comparison.png) | ||
|
||
## 参数介绍 | ||
### Options | ||
|
||
| name | type | required | default value | | ||
|:--------------------------------------------------------------:|:------:|:----------:|:-------------:| | ||
| [database](#database-string) | string | yes | - | | ||
| [table](#table-string) | string | yes | - | | ||
| [actual_execute_sql](#actual_execute_sql-string) | string | yes | - | | ||
| [database2](#database2-string) | string | yes | - | | ||
| [table2](#table2-string) | string | yes | - | | ||
| [expected_execute_sql](#expected_execute_sql-string) | string | yes | - | | ||
|
||
|
||
#### database [string] | ||
源表数据库名 | ||
#### table [string] | ||
源表数据库中的表名 | ||
#### actual_execute_sql [string] | ||
实际值执行SQL,注意 as 后面的别名一定要是 **actual_value**,否则统计会出错。 | ||
#### database2 [string] | ||
目标表数据库名 | ||
#### table2 [string] | ||
目标表数据库中的表名 | ||
#### expected_execute_sql [string] | ||
期望值执行SQL,注意 as 后面的别名一定要是 **expected_value**,否则统计会出错。 | ||
|
||
### 配置文件例子 | ||
``` | ||
{ | ||
"metricType": "multi_table_value_comparison", | ||
"metricParameter": { | ||
"database": "cbs", | ||
"table": "cbs_ratio", | ||
"actual_execute_sql": "select count(1) as actual_value from ${table}", | ||
"database2": "cbs", | ||
"table2": "cbs_ratio", | ||
"expected_execute_sql": "select count(1) as expected_value from ${table2}" | ||
} | ||
} | ||
``` | ||
|
||
## 使用案例 | ||
|
||
### 场景 | ||
|
||
比较某张表(有时间分区列)今天的数据量和昨天的数据量,如果今天的数据量小于昨天的数据量就需要告警。 | ||
|
||
### 思路 | ||
使用两表值比对规则配合内置时间参数。 | ||
|
||
>使用两表值比对的规则,通过编写 SQL 语句来统计今天和昨天的数据量,然后比较两个值,如果今天的值大于昨天的值则为真,否则为假。 | ||
### 步骤 | ||
- 选择数据比对作业中的两表值比对规则 | ||
- 选择对应的数据库和表,并编写计算实际值 SQL 语句。 | ||
- 语句里面用到了`$[today]`时间变量,系统会自动替换成今天的日期,格式为`yyyy-MM-dd`,也可以自己配置格式 `$[today(yyyyMMdd)]`。 | ||
- 注意 as 后面的别名一定要是 **actual_value**,否则统计会出错。 | ||
- 表名可以用`${table}`,系统会自动替换,也可以直接写正确的表名。 | ||
``` | ||
select count(1) as actual_value from ${table} where data_date='$[today]' | ||
``` | ||
- 选择对应的数据库和表,并编写计算期望值 SQL 语句 | ||
- 语句里面用到了`$[yesterday]`时间变量,系统会自动替换成昨天的日期,格式为`yyyy-MM-dd`,也可以自己配置格式 `$[yesterday(yyyyMMdd)]`。 | ||
- 注意 as 后面的别名一定要是 **expected_value**,否则统计会出错。 | ||
- 表名可以用`${table2}`,系统会自动替换,也可以直接写正确的表名。 | ||
``` | ||
select count(1) as expected_value from ${table2} where data_date='$[yesterday]' | ||
``` | ||
- 配置结果判断公式 | ||
- 结果公式选择:实际值-期望值 | ||
- 比较符选择:>= | ||
- 阈值:0 | ||
|
||
如果公式`实际值-期望值 >= 0`的结果为真, 那么就证明今天的表行数大于昨天的表行数,否则就证明今天的表行数小于昨天的表行数,结果是异常的,需要告警。 |
4 changes: 4 additions & 0 deletions
4
docs/04-features/02-metric/02-multi-table-metric/02-multi-table-accuracy.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
id: 'multi-table-accuracy' | ||
title: 'multi_table_accuracy' | ||
--- |
3 changes: 3 additions & 0 deletions
3
docs/04-features/02-metric/02-multi-table-metric/_category_.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"label": "Mutil Table Metric" | ||
} |
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...data-quality/02-engine/01-engine-intro.md → .../04-features/03-engine/01-engine-intro.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
id: 'Engine Introduction' | ||
id: 'engine-introduction' | ||
title: 'Engine Introduction' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
id: 'local-engine' | ||
title: 'Local Engine' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
id: 'spark-engine' | ||
title: 'Spark Engine' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"label": "Job Execute Engine" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
id: 'SLAs' | ||
id: 'slas' | ||
title: 'SLAs' | ||
--- |
2 changes: 1 addition & 1 deletion
2
docs/04-features/04-error-data-storage.md → docs/04-features/05-error-data-storage.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
id: 'Error Data Storage' | ||
id: 'error-data-storage' | ||
title: 'Error Data Storage' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
id: 'Issues' | ||
id: 'issues' | ||
title: 'Issues' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
id: 'Tag' | ||
id: 'tag' | ||
title: 'Tag' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
--- | ||
id: 'DolphinScheduler' | ||
id: 'dolphin-scheduler' | ||
title: 'DolphinScheduler' | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.