All Products
Search
Document Center

DataWorks:StartDISyncInstance

Last Updated:Nov 21, 2024

Starts a real-time synchronization task or a synchronization solution.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
dataworks:*get
*All Resources
*
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ProjectIdlongYes

The ID of the DataWorks workspace. You can log on to the DataWorks console and go to the Workspace page to obtain the workspace ID. You must configure this parameter to specify the DataWorks workspace to which the API operation is applied.

10000
TaskTypestringYes

The type of the object that you want to start. Valid values:

  • DI_REALTIME: real-time synchronization task
  • DI_SOLUTION: data synchronization solution
DI_REALTIME
FileIdlongYes
  • If you set TaskType to DI_REALTIME, set this parameter to the ID of the real-time synchronization task that you want to start.
  • If you set TaskType to DI_SOLUTION, set this parameter to the ID of the data synchronization solution that you want to start.
100
StartParamstringNo
  • If you set TaskType to DI_REALTIME, the StartParam parameter specifies the startup parameters for the real-time synchronization task. The startup parameters include failover-related parameters, the parameter that specifies the number of dirty data records allowed, and the parameters in the data definition language (DDL) statements.
  • If you set TaskType to DI_SOLUTION, the StartParam parameter does not take effect.
{"failoverLimit":{"count":10,"interval":30},"errorLimit":{"record":0},"ddlMarkMap":{"RENAMECOLUMN":"WARNING","DROPTABLE":"WARNING","CREATETABLE":"IGNORE","MODIFYCOLUMN":"WARNING","TRUNCATETABLE":"NORMAL","DROPCOLUMN":"IGNORE","ADDCOLUMN":"NORMAL","RENAMETABLE":"CRITICAL"}}

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

Successboolean

Indicates whether the request was successful. Valid values:

  • true
  • false
true
RequestIdstring

The request ID. You can locate logs and troubleshoot issues based on the ID.

0bc1411515937635973****
Dataobject

The result returned for the start.

Statusstring

Indicates whether the real-time synchronization task or the data synchronization solution is started. Valid values:

  • success: The real-time synchronization task or the data synchronization solution is started.
  • fail: The real-time synchronization task or the data synchronization solution fails to be started. You can troubleshoot the issue based on the provided cause.
success
Messagestring

The reason why the real-time synchronization task or the data synchronization solution fails to be started.

If the real-time synchronization task or the data synchronization solution is started, the value null is returned.

fileId:[100] is invalid.

Examples

Sample success responses

JSONformat

{
  "Success": true,
  "RequestId": "0bc1411515937635973****",
  "Data": {
    "Status": "success",
    "Message": "fileId:[100] is invalid."
  }
}

Error codes

HTTP status codeError codeError messageDescription
400Param.InvalidThe parameter is invalid.Param invalid
403Forbidden.AccessAccess is forbidden.-
500InternalError.SystemAn internal error occurred.InternalError

For a list of error codes, visit the Service error codes.