All Products
Search
Document Center

DataWorks:QueryDISyncTaskConfigProcessResult

Last Updated:Nov 21, 2024

Queries the execution results of an asynchronous task.

Operation description

DataWorks allows you to call only the CreateDISyncTask operation to create a batch synchronization task or the UpdateDISyncTask operation to update a batch synchronization task in Data Integration. To create or update a real-time synchronization task, you must first call the GenerateDISyncTaskConfigForCreating or GenerateDISyncTaskConfigForUpdating operation to obtain the ID of an asynchronous thread and call the QueryDISyncTaskConfigProcessResult operation to obtain the asynchronously generated parameters based on the ID. Then, you can call the CreateDISyncTask or UpdateDISyncTask operation and use the parameters as request parameters to create or update a real-time synchronization task. DataWorks allows you to create or update real-time synchronization tasks in Data Integration only in asynchronous mode.

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

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
ProjectIdlongYes

The DataWorks workspace ID. You can log on to the DataWorks console and go to the Workspace page to obtain the 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 create or update in Data Integration in asynchronous mode. Valid values:

  • DI_REALTIME: real-time synchronization task
  • DI_SOLUTION: synchronization solution DataWorks allows you to create or update real-time synchronization tasks and synchronization solutions in Data Integration only in asynchronous mode.

Valid values:

  • DI_OFFLINE
  • DI_REALTIME
  • DI_SOLUTION
DI_REALTIME
AsyncProcessIdlongYes

The asynchronous thread ID. You can call the GenerateDISyncTaskConfigForCreating or GenerateDISyncTaskConfigForUpdating operation to obtain the ID.

  • The GenerateDISyncTaskConfigForCreating operation is used to generate the ID of the asynchronous thread that is used to create a real-time synchronization task in Data Integration.
  • The GenerateDISyncTaskConfigForUpdating operation is used to generate the ID of the asynchronous thread that is used to update a real-time synchronization task in Data Integration.
10

Response parameters

ParameterTypeDescriptionExample
object

The returned results.

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 information returned for the parameters that are asynchronously generated and used to create or update a real-time synchronization task in Data Integration.

Statusstring

Indicates whether the parameters are obtained. Valid values:

  • success: The parameters are obtained.
  • fail: The parameters fail to be obtained. You can view the reason for the failure and troubleshoot the issue based on the reason.
success
Messagestring

The reason why the parameters fail to be obtained. If the parameters are obtained, the value null is returned.

fileId:[100] is invalid.
TaskContentstring

The parameters that are obtained. The parameters are used as the request parameters of the CreateDISyncTask or UpdateDISyncTask operation to create or update a real-time synchronization task in Data Integration.

{"extend":{"mode":"migration_holo","resourceGroup":"280749","name":"h"},"type":"job","steps":[{"stepType":"mysql","parameter":{"connection":[{"datasourceType":"mysql","datasource":"mm","selectedTables":[{"schema":[{"tableInfos":[{"enable":true,"table":"m_v1","tableName":"m_v1"}]}],"dbName":"m"}]}]},"name":"reader","category":"reader"},{"stepType":"holo","parameter":{"datasource":"h","tableMappingRule":{"datasource":[{"tableRule":[{"srcTable":"m_v1","mergeIntoCycleType":"DEFAULT","hourDeltaEnable":false,"dstTable":"m.m_v1","dayDeltaEnable":false,"primaryKeyInfo":{"column":["id"],"type":"pk"},"dstCreateTableInfo":{"indexType":"m_v1","dataColumn":[{"columnSize":0,"name":"id","index":0,"comment":"","newDigit":0,"type":"int8","digit":0,"primaryKey":true}],"schemaName":"m","tableName":"m_v1"},"srcDbName":"m"],"srcDatasourceName":"mm"}],"totalTableMapping":1},"writeMode":"replay"},"name":"writer","category":"writer"}],"version":"2.0","order":{"hops":[{"from":"reader","to":"writer"}]}}

Examples

Sample success responses

JSONformat

{
  "Success": true,
  "RequestId": "0bc1411515937635973****",
  "Data": {
    "Status": "success",
    "Message": "fileId:[100] is invalid.",
    "TaskContent": "{\"extend\":{\"mode\":\"migration_holo\",\"resourceGroup\":\"280749\",\"name\":\"h\"},\"type\":\"job\",\"steps\":[{\"stepType\":\"mysql\",\"parameter\":{\"connection\":[{\"datasourceType\":\"mysql\",\"datasource\":\"mm\",\"selectedTables\":[{\"schema\":[{\"tableInfos\":[{\"enable\":true,\"table\":\"m_v1\",\"tableName\":\"m_v1\"}]}],\"dbName\":\"m\"}]}]},\"name\":\"reader\",\"category\":\"reader\"},{\"stepType\":\"holo\",\"parameter\":{\"datasource\":\"h\",\"tableMappingRule\":{\"datasource\":[{\"tableRule\":[{\"srcTable\":\"m_v1\",\"mergeIntoCycleType\":\"DEFAULT\",\"hourDeltaEnable\":false,\"dstTable\":\"m.m_v1\",\"dayDeltaEnable\":false,\"primaryKeyInfo\":{\"column\":[\"id\"],\"type\":\"pk\"},\"dstCreateTableInfo\":{\"indexType\":\"m_v1\",\"dataColumn\":[{\"columnSize\":0,\"name\":\"id\",\"index\":0,\"comment\":\"\",\"newDigit\":0,\"type\":\"int8\",\"digit\":0,\"primaryKey\":true}],\"schemaName\":\"m\",\"tableName\":\"m_v1\"},\"srcDbName\":\"m\"],\"srcDatasourceName\":\"mm\"}],\"totalTableMapping\":1},\"writeMode\":\"replay\"},\"name\":\"writer\",\"category\":\"writer\"}],\"version\":\"2.0\",\"order\":{\"hops\":[{\"from\":\"reader\",\"to\":\"writer\"}]}}"
  }
}

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.