This document introduces the Open API for dataset synchronization tasks. You will learn how users can use the API to view and update dataset synchronization task settings, submit dataset synchronization task backtracking, and terminate dataset synchronization task instances.
Caution: Before using the APIs described in this document, you must complete the prerequisites of integrating JWT-Token and applying for a Token. Please first review the invocation method. For details, see Invocation Method.
Permission requirements
Resource | Permission |
|---|---|
Dataset | read |
API description: View the synchronization task settings of a dataset, including synchronization mode, performance parameters, and more.
{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncSettingscurl --location --request GET '{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncSettings' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer {{jwtToken}}'
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
dataSetId | integer | Yes | 123 | Dataset ID |
Parameter | Type | Description |
|---|---|---|
$.backtrackingConf | object | Dataset backtracking configuration |
$.backtrackingConf.dateRange | object | Default backtracking period after the dataset is first created |
$.backtrackingConf.dateRange.endDate | string | Backtracking end time |
$.backtrackingConf.dateRange.startDate | string | Backtracking start time |
$.doradoPriority | string | Synchronization task priority |
$.monitorConf | object | Dataset synchronization monitoring and alert configuration |
$.paramsConfList | object | Advanced parameters for dataset synchronization |
$.performanceSettings | object | Synchronization performance settings |
$.retryInterval | integer | Retry interval for a single dataset task synchronization failure |
$.scheduleDay | string | Synchronization schedule - day |
$.scheduleTime | string | Synchronization schedule - hour |
$.retryNum | integer | Number of retries for a single dataset task synchronization failure |
$.syncType | integer | Dataset task synchronization type [manual, automatic] |
$.writePartition | integer | Dataset synchronization data write partition |
$.ttl | integer | Dataset data retention lifecycle (days) |
{ "code": "aeolus/ok", "data": { "backtrackingConf": { "dateRange": { "endDate": "2022-12-13", "startDate": "2022-12-13" }, "enable": 1 }, "doradoPriority": "normal", "frequency": "daily", "monitorConf": { "alarmRules": [ { "failedAlarmItems": [ { "item": "retry_failed" } ], "id": 6***, "name": "auto_aeolus_rule_{{dataSetId}}_16***********_dev", "normalNoticeConf": [ { "dutySchedules": [], "noticeChannel": "lark", "users": [ "userEmailPrefix" ] } ], "resultAlarmItems": [], "timeoutAlarmItems": [] } ] }, "paramsConfList": [ { "name": "tqs.query.auto.retry.enable", "value": "true" } ], "performanceSettings": { "chQueryParams": {}, "clusterName": "cnch_alpha_lq", "cnchVwDefault": "vw_default", "cnchVwWrite": "vw_write", "driverName": "click_house", "partitionKey": [ "p_date" ], "primaryKeyList": [], "sampleKey": null, "sampleRate": 1.0, "shardKey": null }, "retryInterval": 5, "retryNum": 1, "scheduleDay": "0", "scheduleTime": "00:00", "scheduleTimeType": 0, "slaDaytime": null, "slaStatus": 0, "syncType": 1, "ttl": 7, "upstreamSettings": { "dynamicPartitionConfList": [], "dynamicPartitionMode": false, "partitionConfList": [], "uniqueIndexList": [] }, "writePartition": 0, "yarnName": "root.default_hrtech_da_pm" }, "msg": "成功" }
Permission requirements
Resource | Permission |
|---|---|
Dataset | write |
API description: The content updated by this API is equivalent to modifying the synchronization configuration information—specifically, the synchronization frequency—on the dataset details page frontend.
This API performs a full update. All configuration information must be provided in the request.
{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncSettingscurl --location --request PUT '{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncSettings' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer {{jwtToken}}' \ --data-raw '{ "dataTableConf": { "ttl": 8 }, "syncConf": { "syncType": 1, "scheduleConf": { "frequency": "daily", "scheduleDay": "0", "scheduleTime": "00:00" } } }'
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
dataSetId | integer | Yes | 123 | Dataset ID |
$.dataTableConf.ttl | integer | Yes | 7 | Dataset lifecycle |
$.syncConf.syncType | integer | Yes | 1; 2 | Dataset synchronization scheduling mode [1 for automatic, 2 for manual] |
$.syncConf.scheduleConf | object | Yes | Synchronization scheduling configuration | |
$.syncConf.scheduleConf.frequency | string | Yes | hourly | When using automatic scheduling synchronization, it can be divided into daily, hourly, every ten minutes, monthly, and weekly synchronization. |
$.syncConf.scheduleConf.scheduleDay | string | Yes | 0 | Number of days set for automatic synchronization, the day to start synchronization. For daily, 0 means synchronize every day. |
$.syncConf.scheduleConf.scheduleTime | string | Required | 00:00 | The hour set for automatic synchronization, indicating at which hour of the day synchronization starts. |
{ "code": "aeolus/ok", "data": "{{dataSetId}}", "msg": "成功" }
Permission requirements
Resource | Permission |
|---|---|
Dataset | write |
API description: Update the advanced settings in the dataset synchronization settings, corresponding to the advanced configuration in the dataset frontend synchronization configuration information.
This API performs a full update. All configuration information must be provided in the request.
Request URL: {{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncSettings/advanced
curl --location --request PUT '{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncSettings/advanced' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer {{jwtToken}}' \ --data-raw '{ "yarnName": "root.default_hrtech_da_pm", "doradoPriority": "normal", "retryNum": 3, "retryInterval": 5 }'
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
dataSetId | integer | Required | 123 | Dataset ID |
doradoPriority | integer | Required | normal | Dataset synchronization priority |
retryNum | integer | Required | 1 | Number of retry attempts if dataset synchronization fails |
retryInterval | integer | Required | 5 | Interval between retry attempts for dataset synchronization failures (minutes) |
{ "code": "aeolus/ok", "data": null, "msg": "成功" }
Permission requirements
Resource | Permission |
|---|---|
Dataset | read |
API description: View the list of dataset synchronization tasks, including business date, synchronization status, synchronization time, and more.
{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncJob
curl --location --request GET '{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncJob?startDate=2022-12-13&endDate=2022-12-15&nodeId' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer {{jwtToken}}'
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
dataSetId | integer | Required | 123 | Dataset ID |
startDate | string | Required | 2022-12-07 | Start time of the business date range for the synchronization task |
endDate | string | Required | 2022-12-11 | End time of the business date range for the synchronization task |
nodeId | string | Optional | af2f28ea-f96a-49f9-ac99-7587364df5f4 | Synchronization task list for the dimension table |
Parameter | Type | Description |
|---|---|---|
bizTime | string | Dataset backtracking configuration |
bizTimePage | string | Default backtracking period after the dataset is first created |
diagPageUrl | string | Synchronization task diagnostic page URL |
instanceDurationTime | string | Synchronization duration of the task instance |
instanceId | integer | Synchronization task instance ID |
logPageUrl | string | Synchronization task instance log URL |
scheduledStartTime | string | Start time of the synchronization task instance |
syncEndTime | string | End time of the synchronization task instance |
tableSize | integer | Data size synchronized by the task instance |
syncStatus | integer | Synchronization task instance status |
{ "code": "aeolus/ok", "data": { "instanceList": [ { "bizTime": "2022-12-15 00:00:00", "bizTimePage": "2022-12-15", "diagPageUrl": "https://data.bytedanc*.net/dorado/instance-detail/diagnosis?project=cn_756&id=108301911&schedule=2022-12-15%2000%3A00%3A00&pid=756&status=2&instanceId=1324365220&groupName=cn", "instanceDurationTime": null, "instanceId": 1324365220, "instanceSign": "8332ea1af3a3d960**************", "logPageUrl": "https://data.bytedanc*.net/dorado/instance-detail/log?project=cn_7**&id=1********&schedule=2022-12-15%2000%3A00%3A00&pid=7**&instanceId=1324365220&groupName=cn", "scheduledStartTime": "2022-12-16 00:00:00", "syncEndTime": null, "syncStartTime": null, "syncStatus": 2, "syncStatusDescCode": 3, "tableSize": "-", "taskId": 9178 }, { "bizTime": "2022-12-14 00:00:00", "bizTimePage": "2022-12-14", "diagPageUrl": "https://data.bytedanc*.net/dorado/instance-detail/diagnosis?project=cn_756&id=108******&schedule=2022-12-14%2000%3A00%3A00&pid=756&status=4&instanceId=132*******&groupName=cn", "instanceDurationTime": 501.0, "instanceId": 1322531180, "instanceSign": "b1285**************", "logPageUrl": "https://data.bytedanc*.net/dorado/instance-detail/log?project=cn_756&id=108******&schedule=2022-12-14%2000%3A00%3A00&pid=756&instanceId=132*******&groupName=cn", "scheduledStartTime": "2022-12-15 00:00:00", "syncEndTime": "2022-12-15 00:33:29", "syncStartTime": "2022-12-15 00:25:08", "syncStatus": 4, "syncStatusDescCode": 30, "tableSize": "56", "taskId": 9*** }, { "bizTime": "2022-12-13 00:00:00", "bizTimePage": "2022-12-13", "diagPageUrl": "https://data.bytedanc*.net/dorado/instance-detail/diagnosis?project=cn_756&id=108301911&schedule=2022-12-13%2000%3A00%3A00&pid=7**&status=4&instanceId=132*******&groupName=cn", "instanceDurationTime": 1197.0, "instanceId": 1322222925, "instanceSign": "af3a3d960**************", "logPageUrl": "https://data.bytedanc*.net/dorado/instance-detail/log?project=cn_756&id=108*******&schedule=2022-12-13%2000%3A00%3A00&pid=7**&instanceId=132*******&groupName=cn", "scheduledStartTime": "2022-12-14 00:00:00", "syncEndTime": "2022-12-14 12:38:57", "syncStartTime": "2022-12-14 12:19:00", "syncStatus": 4, "syncStatusDescCode": 30, "tableSize": "56", "taskId": 9178 } ], "total": 3 }, "msg": "成功" }
Definition of example values for dataset task instance statuses.
syncStatus values | Instance status |
|---|---|
1 | Not ready |
2 | Waiting for execution |
3 | In progress |
4 | Execution successful |
5 | Execution failed |
6 | Terminated |
Permission requirements
Resource | Permission |
|---|---|
Dataset | write |
Interface description and notes: Batch submit synchronization task instances to perform data backtracking.
Caution: The selectable range for the backtracking date and time period must be less than or equal to the dataset's data lifecycle (ttl).
{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncJobcurl --location --request POST '{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/syncJob' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer {{jwtToken}}' \ --data-raw '{ "nodeId": "", "startDate": "2022-12-07", "endDate": "2022-12-11", "checkMinMax": true, "skipCheck": true, "isSpecifyQueue": true, "queueName": "root.oryx_aeolus_vip", "maxParallelism": 10 }'
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
dataSetId | integer | Required | 123 | Dataset ID |
nodeId | string | Optional | af2f28ea-f96a-49f9-ac99-7587364df5f4 | If not specified, the primary table data is backtracked by default; if specified, the dimension table data is backtracked. |
startDate | string | Required | 2022-12-07 | Backtracking start time of the business date range for the synchronization task |
endDate | string | Required | 2022-12-11 | Backtracking end time of the business date range for the synchronization task |
checkMinMax | bool | Optional | true | Check whether the synchronization partition range exceeds the limit |
skipCheck | bool | Optional | true | Skip dependency check |
isSpecifyQueue | bool | Optional | true | Whether to specify queue backtracking (non-TOB environment) |
queueName | string | Optional | root.oryx_aeolus_vip | Specified queue name (non-TOB environment) |
maxParallelism | integer | Optional | 10 | The maximum number of rows for the current synchronization task instance, mainly used for batch backtracking to prevent all backtracking instances from being triggered and executed at the same time. |
{ "code": "aeolus/ok", "data": "ok", "msg": "成功" }
Permission requirements
Resource | Permission |
|---|---|
Dataset | write |
Interface description and notes: Batch terminate task instances. Available in version 2.60.0.
{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/stopSyncJobcurl --location --request POST '{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/stopSyncJob' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer {{jwtToken}}' \ --data-raw '{ "instanceList": [ { "id": 226*******, "taskTime": "2023-12-25 00:00:00", "sign": "" }, { "id": 226*******, "taskTime": "2023-12-24 00:00:00" } ], "nodeId": "" }'
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
$.nodeId | string | No | af2f28ea-f96a-49f9-ac99-7587364df5f4 | If not specified, the primary table task instance will be terminated by default; if specified, the dimension table task instance will be terminated. |
$.instanceList | object | Yes | Scope of instances to terminate | |
$.instanceList.id | string | Yes | 2263796858 | ID of the task instance to terminate. The instanceId can be obtained from the Get dataset synchronization task status API. |
$.instanceList.taskTime | string | Yes | 2023-12-25 00:00:00 | Business date of the task instance to terminate. The bizTime can be obtained from the Get dataset synchronization task status API. |
$.instanceList.sign | string | Yes | f2244702cb94ef3d405f60985b421835 | Signature of the synchronization task instance. The instanceSign can be obtained from the Get dataset synchronization task status API. |
{ "code": "aeolus/ok", "data": "ok", "msg": "成功" }
Resource | Permission |
|---|---|
Dataset | read |
{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/instanceInfocurl --location --request POST '{{domain}}/aeolus/api/v4/open/dataset/{{dataSetId}}/instanceInfo' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer {{jwtToken}}' \ --data-raw '{"instance_id_list": [94]}'
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
instance_id_list | array | Yes | ["2263796858"] | Set of synchronization task instance IDs. The instance IDs can be obtained from the instanceId field in the Get dataset synchronization task status API. |
Name | Type | Description |
|---|---|---|
id | integer | Synchronization task instance ID |
scheduleTaskId | integer | Synchronization task ID |
subTaskId | integer | Synchronization task output node ID |
taskId | integer | Synchronization task PrepID |
appExternalId | string | YARN task ID |
createTime | string | Synchronization task instance creation time |
taskTime | string | Synchronization task instance business date |
startTime | string | Synchronization task instance start time |
endTime | string | Synchronization task instance end time |
scheduleTime | string | Synchronization task instance schedule time |
status | string | Synchronization task instance status |
triggerType | string | Synchronization task instance trigger type. Values: SCHEDULED (routine), BACKFILL (backfill). |
{ "code": "aeolus/ok", "data": [ "id": 94, "scheduleTaskId": 3, "subTaskId": 2, "taskId": 1, "appExternalId": "application_17***********_****", "createTime": "2024-02-23 23:00:00", "taskTime": "2024-02-23 20:00:00", "startTime": "2024-02-24 00:01:01", "endTime": "2024-02-24 00:02:01", "scheduleTime": "2024-02-24 00:00:00", "status": "SUCCEEDED", "triggerType": "BACKFILL" ] "msg": "成功" }