Updates a synchronization task.
Operation description
This API operation is available for all DataWorks editions.
Debugging
Authorization information
Request parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
| Id | long | No | The ID of the synchronization task. | 11588 |
| Description | string | No | The task description. | The description of the synchronization task. |
| TableMappings | array<object> | No | The list of synchronization object transformation mappings. Each element describes a set of source object selection rules and the transformation rules applied to those objects. Note
[ { "SourceObjectSelectionRules":[ { "ObjectType":"Database", "Action":"Include", "ExpressionType":"Exact", "Expression":"biz_db" }, { "ObjectType":"Schema", "Action":"Include", "ExpressionType":"Exact", "Expression":"s1" }, { "ObjectType":"Table", "Action":"Include", "ExpressionType":"Exact", "Expression":"table1" } ], "TransformationRuleNames":[ { "RuleName":"my_database_rename_rule", "RuleActionType":"Rename", "RuleTargetType":"Schema" } ] } ]
| |
| object | No | The list of synchronization object transformation mappings. Each element describes a set of source object selection rules and the transformation rules applied to those objects. | ||
| SourceObjectSelectionRules | array<object> | No | Each rule can select different object types from the source, such as source databases and source tables. | |
| object | No | Each rule can select different object types from the source, such as source databases and source tables. | ||
| Action | string | No | Valid values: Include and Exclude. | Include |
| Expression | string | No | The expression. | mysql_table_1 |
| ExpressionType | string | No | The expression type. Valid values: Exact and Regex. | Exact |
| ObjectType | string | No | The object type. Valid values:
| Table |
| TransformationRules | array<object> | No | The transformation rules applied to source objects. | |
| object | No | The transformation rules applied to source objects. | ||
| RuleName | string | No | The rule name. The rule name must be unique for a given combination of action type and target type. The name cannot exceed 50 characters. | rename_rule_1 |
| RuleActionType | string | No | Valid values:
| Rename |
| RuleTargetType | string | No | Valid values:
| Table |
| JobSettings | object | No | The task-level settings, including DDL handling policies, column data type mapping between source and destination, and runtime parameters. | |
| ChannelSettings | string | No | The channel-specific settings. You can configure special settings for specific channels. Currently supported: Holo2Holo (Hologres to Hologres) and Holo2Kafka (Hologres to Kafka).
| {"structInfo":"MANAGED","storageType":"TEXTFILE","writeMode":"APPEND","partitionColumns":[{"columnName":"pt","columnType":"STRING","comment":""}],"fieldDelimiter":""} |
| ColumnDataTypeSettings | array<object> | No | The array of column type mappings. Note
["ColumnDataTypeSettings":[ { "SourceDataType":"Bigint", "DestinationDataType":"Text" } ]
| |
| object | No | A single column type mapping. | ||
| DestinationDataType | string | No | The destination type, such as bigint, boolean, string, text, datetime, timestamp, decimal, or binary. Different data sources may have different types. | text |
| SourceDataType | string | No | The source type, such as bigint, boolean, string, text, datetime, timestamp, decimal, or binary. Different data sources may have different types. | bigint |
| CycleScheduleSettings | object | No | The scheduled task settings. | |
| ScheduleParameters | string | No | The scheduling parameters. | bizdate=$bizdate |
| DdlHandlingSettings | array<object> | No | The array of DDL handling settings. Note
["DDLHandlingSettings":[ { "Type":"Insert", "Action":"Normal" } ]
| |
| object | No | A single DDL handling setting. | ||
| Action | string | No | Valid values:
| Critical |
| Type | string | No | The DDL type. Valid values:
| AddColumn |
| RuntimeSettings | array<object> | No | The runtime settings. | |
| object | No | The runtime settings. | ||
| Name | string | No | The setting name. Valid values:
| runtime.offline.concurrent |
| Value | string | No | The setting value. | 1 |
| ResourceSettings | object | No | The resource settings. | |
| OfflineResourceSettings | object | No | The batch synchronization resources. | |
| RequestedCu | long | No | The CUs of the resource group for Data Integration used for batch synchronization. | 2.0 |
| ResourceGroupIdentifier | string | No | The name of the resource group for Data Integration that are used for batch synchronization. | S_res_group_111_222 |
| RealtimeResourceSettings | object | No | The real-time synchronization resources. | |
| RequestedCu | long | No | The CUs of the resource group for Data Integration that are used for real-time synchronization. | 2.0 |
| ResourceGroupIdentifier | string | No | The name of the resource group for Data Integration that are used for real-time synchronization. | S_res_group_111_222 |
| ScheduleResourceSettings | object | No | The resource used for scheduling. | |
| RequestedCu | long | No | The CUs of the scheduling resource group for batch synchronization tasks. | 2.0 |
| ResourceGroupIdentifier | string | No | The name of the scheduling resource group used for batch synchronization tasks. | S_res_group_235454102432001_1721021993437 |
| TransformationRules | array<object> | No | The list of synchronization object transformation rule definitions. Note
[ { "RuleName":"my_database_rename_rule", "RuleActionType":"Rename", "RuleTargetType":"Schema", "RuleExpression":"{"expression":"${srcDatasoureName}_${srcDatabaseName}"}" } ]
| |
| object | No | A single synchronization object transformation rule definition. | ||
| RuleActionType | string | No | Valid values:
| Rename |
| RuleExpression | string | No | The rule expression in JSON string format.
| {"expression":"${srcDatasoureName}_${srcDatabaseName}"} |
| RuleName | string | No | The rule name. When the action type and target type are the same, the rule name must be unique. The name cannot exceed 50 characters. | rename_rule_1 |
| RuleTargetType | string | No | The target type for the action. Valid values:
| Table |
| ProjectId | long | No | The DataWorks workspace ID. You can call the ListProjects operation to obtain the ID. | 10000 |
DIJobIddeprecated | long | No | This parameter is deprecated. Use the Id parameter instead. | 11588 |
| Owner | string | No | The task owner. | 95279527 |
Response parameters
Examples
Sample success responses
JSONformat
{
"Success": true,
"RequestId": "AAC30B35-820D-5F3E-A42C-E96BB6379325"
}Error codes
For a list of error codes, visit the Service error codes.
Change history
| Change time | Summary of changes | Operation |
|---|---|---|
| 2025-01-06 | The request parameters of the API has changed | View Change Details |
| 2024-12-11 | The internal configuration of the API is changed, but the call is not affected | View Change Details |
| 2024-10-14 | The request parameters of the API has changed | View Change Details |
