查询资产血缘
接口描述
本接口用于获取指定资产的上下游血缘关系。
接口URL
GET http://{anymetrics_host:anymetrics_port}/anymetrics/api/v1/lineage/queryVertexLineage
anymetrics_host:anymetrics_port 获取方式请参考:调用方式
请求参数
公共请求参数(HEADERS)
| 参数 | 类型 | 是否必选 | 最大长度 | 描述 | |
|---|---|---|---|---|---|
| tenant-id | String | 是 | 32 | 租户ID,用于指标查询内容所在的租户 |
|
| auth-type | String | 是 | 32 | 认证方式支持: UID(基于用户ID认证) TOKEN(基于令牌认证)。 |
|
| auth-value | String | 是 | 32 | 与选定的auth-type相对应的认证值。 |
请求参数
| 参数 | 类型 | 是否必选 | 描述 | |
|---|---|---|---|---|
| vertex_id | String | 是 | 点ID | |
| vertex_type | String | 是 | 点类型 | |
| input_step | Integer | 是 | 点输入边跳数 | |
| output_step | Integer | 是 | 点输出边跳数 |
资源说明
血缘关系说明

点类型及其说明
| 点类型 | 点 ID说明 | ID示例 |
|---|---|---|
| FILE | 文件在引擎中的 GUID,格式为 catalog.schema.table,三段式分别代表 catalog、schema、table。 |
aloudata_am_upload_database_dev.public.product |
| FILE_COLUMN | 文件上传表的列,在文件 GUID 的基础上加上列名,格式为 catalog.schema.table.column。 |
aloudata_am_upload_database_dev.public.product.product_name |
| PHYSICAL_TABLE | 物理表在引擎中的 GUID,格式为 catalog.schema.table。 |
default_catalog.anymetrics.tb_order |
| PHYSICAL_TABLE_COLUMN | 物理表的列,在物理表 GUID 的基础上加上列名,格式为 catalog.schema.table.column。 |
default_catalog.anymetrics.tb_order.order_amt |
| DATASET | 数据集名称。 | tb_order |
| DATASET_COLUMN | 数据集名称 + 数据集列名,格式为 dataset.column。 |
tb_order.order_amt |
| DIMENSION | 维度名称,即维度属性的 dimName。 | tb_order_city |
| METRIC | 指标名称,即指标属性的 metricName。 | 7d_sum_order_amt |
| ANALYSIS_VIEW | 指标视图名称。 | 7d_sum_order_amt_view |
请求示例
http://127.0.0.1:8083/anymetrics/api/v1/lineage/queryVertexLineage?input_step=1&output_step=1&vertex_id=DFGHJK&vertex_type=METRIC
响应示例
{
"data": {
"vertexList": [
{
"vertexId": "DWD_CW_YFHZ",
"vertexType": "DATASET",
"displayName": "DWD_CW_YFHZ",
"description": "",
"custom": null
},
{
"vertexId": "DWD_CW_YFHZ.YWFWDM",
"vertexType": "DATASET_COLUMN",
"displayName": null,
"description": null,
"custom": null
},
{
"vertexId": "DFGHJK",
"vertexType": "METRIC",
"displayName": "GHJDFGHJ",
"description": "CVBN",
"custom": {
"originDataType": "BIGINT",
"type": "ATOMIC",
"category": [
{
"name": "未分类",
"id": "-1"
}
]
}
},
{
"vertexId": "date_dimension.year",
"vertexType": "DATASET_COLUMN",
"displayName": null,
"description": null,
"custom": null
},
{
"vertexId": "DWD_CW_YFHZ.CJRQ",
"vertexType": "DATASET_COLUMN",
"displayName": null,
"description": null,
"custom": null
},
{
"vertexId": "test1",
"vertexType": "ANALYSIS_VIEW",
"displayName": "test1",
"description": "",
"custom": null
}
],
"edgeList": [
{
"srcVertex": {
"vertexId": "DWD_CW_YFHZ.YWFWDM",
"vertexType": "DATASET_COLUMN"
},
"dstVertex": {
"vertexId": "DFGHJK",
"vertexType": "METRIC"
},
"edgeType": "COLUMN_IMPACT"
},
{
"srcVertex": {
"vertexId": "date_dimension.year",
"vertexType": "DATASET_COLUMN"
},
"dstVertex": {
"vertexId": "DFGHJK",
"vertexType": "METRIC"
},
"edgeType": "COLUMN_IMPACT"
},
{
"srcVertex": {
"vertexId": "DWD_CW_YFHZ.CJRQ",
"vertexType": "DATASET_COLUMN"
},
"dstVertex": {
"vertexId": "DFGHJK",
"vertexType": "METRIC"
},
"edgeType": "COLUMN_IMPACT"
},
{
"srcVertex": {
"vertexId": "DWD_CW_YFHZ",
"vertexType": "DATASET"
},
"dstVertex": {
"vertexId": "DFGHJK",
"vertexType": "METRIC"
},
"edgeType": "TABLE_IMPACT"
},
{
"srcVertex": {
"vertexId": "DFGHJK",
"vertexType": "METRIC"
},
"dstVertex": {
"vertexId": "test1",
"vertexType": "ANALYSIS_VIEW"
},
"edgeType": "TABLE_IMPACT"
}
]
},
"success": true,
"code": "200",
"errorMsg": null,
"detailErrorMsg": null,
"traceId": "260f158866654614b2ac8f1392995c3a.11134.17346624665670963"
}