Panggil ListQualityRules untuk mengambil aturan kualitas yang cocok dengan ekspresi partisi.
API ini telah ditinggalkan. Kami merekomendasikan migrasi ke dataworks-public(2024-05-18) - GetDataQualityScan guna memperoleh fungsionalitas yang lebih baik dan dukungan berkelanjutan. Meskipun API yang telah ditinggalkan ini masih dapat diakses sementara, tidak akan ada pembaruan atau perbaikan bug lebih lanjut.
Coba sekarang
Test
RAM authorization
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| ProjectName |
string |
Yes |
Nama mesin atau sumber data. Anda dapat menemukan nama ini pada halaman Konfigurasi Sumber Data. |
autotest |
| EntityId |
integer |
Yes |
ID ekspresi partisi. Panggil operasi GetQualityEntity untuk mendapatkan ID ini. |
12345 |
| PageNumber |
integer |
Yes |
Nomor halaman. |
1 |
| PageSize |
integer |
Yes |
Jumlah entri yang dikembalikan per halaman. Default: 10. Maksimum: 20. |
20 |
| ProjectId |
integer |
Yes |
ID ruang kerja DataWorks. |
12345 |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
Objek respons. |
||
| HttpStatusCode |
integer |
Kode status HTTP. |
200 |
| RequestId |
string |
ID permintaan. |
38cbdef0-f6cf-49**** |
| ErrorMessage |
string |
Pesan kesalahan. |
You have no permission. |
| Success |
boolean |
Menunjukkan apakah permintaan berhasil. Nilai yang valid:
|
true |
| ErrorCode |
string |
Kode kesalahan. |
Invalid.Tenant.ConnectionNotExists |
| Data |
object |
Daftar aturan kualitas yang dipaginasi. |
|
| PageNumber |
integer |
Nomor halaman. |
1 |
| PageSize |
integer |
Jumlah entri per halaman. Nilai yang valid adalah 1 hingga 100. Nilai default: 10. |
20 |
| TotalCount |
integer |
Jumlah total entri yang dikembalikan. |
400 |
| Rules |
array<object> |
Detail aturan kualitas. |
|
|
object |
Data yang dikembalikan. |
||
| BlockType |
integer |
The strength of the monitoring rule. The strength of a monitoring rule indicates the importance of the rule. Valid values:
|
0 |
| OnDutyAccountName |
string |
The name of the Alibaba Cloud account that is used to configure the monitoring rule. |
test |
| Property |
string |
The name of the field. |
id |
| WarningThreshold |
string |
The threshold for a warning alert. The threshold specifies the deviation of the monitoring result from the expected value. You can specify a custom value for the threshold based on your business requirements. |
10 |
| TableName |
string |
The name of the table. |
dual |
| OnDuty |
string |
The name of the Alibaba Cloud account that is used to configure the monitoring rule. |
1912**** |
| Comment |
string |
The description of the monitoring rule. |
Verify table rules |
| RuleCheckerRelationId |
integer |
The ID of the task that is associated with the partition filter expression. |
132323 |
| FixCheck |
boolean |
Indicates whether the monitoring is performed based on a fixed value. |
true |
| MethodId |
integer |
The ID of the task that is associated with the partition filter expression. |
21 |
| TemplateName |
string |
The name of the monitoring template. |
Number of SQL task table rows, 1, 7, and 30 days wave detection |
| Trend |
string |
The trend of the monitoring result. |
abs |
| HistoryWarningThreshold |
string |
The historical threshold for a warning alert. |
history max:40%,history min:10% |
| RuleType |
integer |
Rule type:
|
0 |
| MatchExpression |
string |
The partition filter expression. |
dt=$[yyyymmdd] |
| ProjectName |
string |
The name of the compute engine or data source. |
autotest |
| PropertyKey |
string |
The field that is used to associate with monitoring rules at the frontend. This parameter can be ignored. |
table_count |
| CriticalThreshold |
string |
The threshold for a critical alert. The threshold indicates the deviation of the monitoring result from the expected value. You can specify a custom value for the threshold based on your business requirements. If a monitoring rule is a strong rule and the critical threshold is exceeded, a critical alert is reported and tasks that are associated with the rule are blocked from running. |
40 |
| HistoryCriticalThreshold |
string |
The historical threshold for a critical alert. |
history max:80%,history min:50% |
| MethodName |
string |
The method that is used to collect sample data, such as avg, count, sum, min, max, count_distinct, user_defined, table_count, table_size, table_dt_load_count, table_dt_refuseload_count, null_value, null_value/table_count, (table_count-count_distinct)/table_count, or table_count-count_distinct. |
count/table_count |
| CheckerId |
integer |
The checker ID. |
7 |
| EntityId |
integer |
The ID of the partition filter expression. |
1234 |
| ExpectValue |
string |
The expected value. |
1000 |
| TemplateId |
integer |
The ID of the monitoring template. |
7 |
| Id |
integer |
The monitoring rule ID. |
1234 |
| RuleName |
string |
The name of the monitoring rule. |
test |
Contoh
Respons sukses
JSONformat
{
"HttpStatusCode": 200,
"RequestId": "38cbdef0-f6cf-49****",
"ErrorMessage": "You have no permission.",
"Success": true,
"ErrorCode": "Invalid.Tenant.ConnectionNotExists",
"Data": {
"PageNumber": 1,
"PageSize": 20,
"TotalCount": 400,
"Rules": [
{
"BlockType": 0,
"OnDutyAccountName": "test",
"Property": "id",
"WarningThreshold": "10",
"TableName": "dual",
"OnDuty": "1912****",
"Comment": "Verify table rules",
"RuleCheckerRelationId": 132323,
"FixCheck": true,
"MethodId": 21,
"TemplateName": "Number of SQL task table rows, 1, 7, and 30 days wave detection",
"Trend": "abs",
"HistoryWarningThreshold": "history max:40%,history min:10%",
"RuleType": 0,
"MatchExpression": "dt=$[yyyymmdd]",
"ProjectName": "autotest",
"PropertyKey": "table_count",
"CriticalThreshold": "40",
"HistoryCriticalThreshold": "history max:80%,history min:50%",
"MethodName": "count/table_count",
"CheckerId": 7,
"EntityId": 1234,
"ExpectValue": "1000",
"TemplateId": 7,
"Id": 1234,
"RuleName": "test"
}
]
}
}
Kode kesalahan
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.