Queries the ancestor nodes of a node.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes GetNodeParents

The operation that you want to perform.

NodeId Long Yes 12345456211234

The ID of the node. You can go to the Operation Center page in the DataWorks console to view the ID.

ProjectEnv String Yes PROD

The environment of the DataWorks workspace. Valid values: PROD and DEV. The value PROD indicates a production environment, and the value DEV indicates a development environment.

RegionId String Yes cn-shanghai

The region ID. For example, the ID of the China (Shanghai) region is cn-shanghai, and that of the China (Zhangjiakou) region is cn-zhangjiakou. The system automatically determines the value of this parameter based on the endpoint used to call the operation.

Response parameters

Parameter Type Example Description
Data Struct

The information of the ancestor nodes.

Nodes Array of Nodes

The ancestor nodes returned.

BaselineId Long 1244564565

The ID of the baseline.

CronExpress String 00 00 * * * *

The cron expression. The cron expression is used to run an auto triggered node.

NodeId Long 1244564565

The ID of the node.

NodeName String test_Node

The name of the node.

OwnerId String 123124561341251321

The ID of the Alibaba Cloud account used by the node owner.

Priority Integer 3

The priority of the node. Valid values: 1 to 8. A larger value indicates a higher priority.

ProgramType String ODPS_SQL

The type of the node.

ProjectId Long 12315412412

The ID of the workspace to which the node belongs.

Repeatability Boolean true

Indicates whether the node can be rerun if the running of the node fails. Valid values:

  • true: indicates that the node can be rerun.
  • false: indicates that the node cannot be rerun.
SchedulerType String NORMAL

The scheduling type of the node. Valid values:

  • NORMAL: indicates that the node is a normal auto triggered node.
  • MANUAL: indicates that the node is a manually triggered node.
    • PAUSE: indicates that the node is a paused node. Paused nodes are started as scheduled but the system sets the status of the nodes to failed when it starts to run them.
  • SKIP: indicates that the node is a dry-run node. Dry-run nodes are started as scheduled but the system sets the status of the nodes to successful when it starts to run them.
ErrorCode String 1060010000000

The error code returned.

ErrorMessage String err

The error message returned.

HttpStatusCode Integer 200

The HTTP status code returned.

RequestId String asdfasdfas-adfasdf-asfas-dfasdf-asdf

The ID of the request. You can troubleshoot issues based on the ID.

Success Boolean true

Indicates whether the request is successful.

Examples

Sample requests

http(s)://[Endpoint]/?Action=GetNodeParents
&NodeId=12345456211234
&ProjectEnv=PROD
&RegionId=cn-shanghai
&<Common request parameters>

Sample success responses

XML format

<RequestId>asdfasdfas-adfasdf-asfas-dfasdf-asdf</RequestId>
<HttpStatusCode>200</HttpStatusCode>
<Data>
    <Nodes>
        <BaselineId>1244564565</BaselineId>
        <Repeatability>true</Repeatability>
        <OwnerId>123124561341251321</OwnerId>
        <NodeName>test_Node</NodeName>
        <Priority>3</Priority>
        <ProjectId>12315412412</ProjectId>
        <NodeId>1244564565</NodeId>
        <ProgramType>ODPS_SQL</ProgramType>
        <SchedulerType>NORMAL</SchedulerType>
        <CronExpress>00 00 * * * *</CronExpress>
    </Nodes>
</Data>
<ErrorCode>1060010000000</ErrorCode>
<ErrorMessage>err</ErrorMessage>
<Success>true</Success>

JSON format

{
    "RequestId": "asdfasdfas-adfasdf-asfas-dfasdf-asdf",
    "HttpStatusCode": 200,
    "Data": {
        "Nodes": {
            "BaselineId": 1244564565,
            "Repeatability": true,
            "OwnerId": 123124561341251330,
            "NodeName": "test_Node",
            "Priority": 3,
            "ProjectId": 12315412412,
            "NodeId": 1244564565,
            "ProgramType": "ODPS_SQL",
            "SchedulerType": "NORMAL",
            "CronExpress": "00 00 * * * *"
        }
    },
    "ErrorCode": 1060010000000,
    "ErrorMessage": "err",
    "Success": true
}

Error codes

For a list of error codes, visit the API Error Center.