Registers the lineage between self-managed entities to DataWorks and allows the lineage to be combined with the existing lineage between system entities in DataWorks to form a full-link lineage.
This operation is in the trial phase. Users who need to call this operation can apply for it. The users can call this operation after the administrator adds the users to the trial list.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
Action | String | Yes | RegisterLineageRelation | The operation that you want to perform. Set the value to RegisterLineageRelation. |
LineageRelationRegisterVO | Yes | The structure whose lineage you want to register to DataWorks. |
Format of the unique identifier of an entity: EntityType.EntityGuid
1. The EntityType parameter identifies the type of an entity.
1.1 Existing entity types in DataWorks
(1) MaxCompute table: maxcompute-table
(2) MySQL table: mysql-table
(3) EMR table: emr-table
(4) Hologres table: holodb-table
1.2 Custom entity types: custom-xxx
The following entity types are recommended based on user requirements:
(1) Table: custom-table
(2) API: custom-api
(3) Application: custom-app
(4) Report: custom-report
(5) Dataset: custom-dataset
(6) Data source: custom-datasource
2. The EntityGuid parameter specifies the unique identifier of an entity among multiple entities of the same type.
Users can define the unique ID for a custom entity based on their business requirements.
3. Sample entity:
3.1 The existing lineage between system entities in DataWorks can be viewed in lineage graphs on the Data Map page.
(1) maxcompute-table.project.tableName specifies the unique ID of a MaxCompute table.
(2) emr-table.kadfdfaccdd4ted specifies the unique ID of an E-MapReduce (EMR) table.
3.2 Users can define the unique ID for a custom entity based on their business requirements. The unique ID cannot exceed 50 bytes in length.
(1) custom-api.listUser: Specifies a custom API entity. The unique identifier of the entity is listUser.
(2) custom-table.db1.table2: Specifies a custom table entity. The unique identifier of the entity is db1.table2.
Response parameters
Parameter | Type | Example | Description |
HttpStatusCode | Integer | 200 | The HTTP status code returned. |
ErrorMessage | String | The entity of lineage not exist, xxx | The error message returned. |
RequestId | String | EE50E05E-028C-182B-9xxx | The request ID. You can locate logs and troubleshoot issues based on the ID. |
Success | Boolean | true | Indicates whether the request was successful. Valid values:
|
ErrorCode | String | 1010210001 | The error code returned. |
LineageRelation | Object | The lineage. | |
SrcEntityQualifiedName | String | maxcompute-table.project.table | The unique identifier of the source entity. |
DestEntityQualifiedName | String | custom-report.month_stat_user | The unique identifier of the destination entity. |
RelationshipGuid | String | dfsldfdlsfdsaaaabbbb | The ID of the lineage between entities. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=RegisterLineageRelation
&LineageRelationRegisterVO={"SrcEntity":{"QualifiedName":"maxcompute-table.projectName.tablename","Name":"tableName","ParentName":"dbName","DetailUrl":"http://domain.test.url/entity"},"DestEntity":{"QualifiedName":"maxcompute-table.projectName.tablename","Name":"tableName","ParentName":"dbName","DetailUrl":"http://domain.test.url/entity"},"Relationship":{"Type":"sql"},"CreateTimestamp":1684327487964}
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<RegisterLineageRelationResponse>
<HttpStatusCode>200</HttpStatusCode>
<ErrorMessage>The entity of lineage not exist, xxx</ErrorMessage>
<RequestId>EE50E05E-028C-182B-9xxx</RequestId>
<Success>true</Success>
<ErrorCode>1010210001</ErrorCode>
<LineageRelation>
<SrcEntityQualifiedName>maxcompute-table.project.table</SrcEntityQualifiedName>
<DestEntityQualifiedName>custom-report.month_stat_user</DestEntityQualifiedName>
<RelationshipGuid>dfsldfdlsfdsaaaabbbb</RelationshipGuid>
</LineageRelation>
</RegisterLineageRelationResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"HttpStatusCode" : 200,
"ErrorMessage" : "The entity of lineage not exist, xxx",
"RequestId" : "EE50E05E-028C-182B-9xxx",
"Success" : true,
"ErrorCode" : 1010210001,
"LineageRelation" : {
"SrcEntityQualifiedName" : "maxcompute-table.project.table",
"DestEntityQualifiedName" : "custom-report.month_stat_user",
"RelationshipGuid" : "dfsldfdlsfdsaaaabbbb"
}
}
Error codes
For a list of error codes, see Service error codes.