跳到主要内容

查询表映射

接口描述

根据 表/topic/collection 等源端同步元素,查询目的端元数据

接口地址

/cloudcanal/console/api/v1/openapi/schema/querybytransferobjname

请求方式

POST

请求参数

参数名称参数说明请求类型是否必须数据类型
transferObjName同步任务源端数据源 表/topic/collection 等信息bodystring

公共响应结果

参数名称参数说明类型(java)不为空
code1:成功 0:失败string
dataobject
msgstring
requestIdstring

data 参数说明

data 为数组,其中每一组数据中的字段说明如下:

参数名称参数说明类型(java)不为空
srcTransferObjName同步任务源端数据源 表/topic/collection 等信息string
targetSchemaObjs对象数组,每一个元素表示一个目的端array

targetSchemaObjs 元素字段说明

参数名称参数说明类型(java)不为空
dataJobIdData Job idlong
dataJobNameData Job 名称string
dataJobDescData Job 描述string
db对端数据库名称,如ORACLE/PostgreSQL/SQLServer等不为空,MySQL/Kafka/MongoDB/StarRocks/Doris/ClickHouse/Kafka/RocketMQ/RabbitMq等为空string
schema对端schema名称,ORACLE/PostgreSQL/SQLServer/MySQL/MongoDB/StarRocks/Doris/ClickHouse等不为空,Kafka/RocketMQ/RabbitMq为空string
transferObjName对端 表/index/topic/collectionstring

响应示例

{
"taskId": 0,
"workerIdentity": null,
"sendBackToTask": false,
"code": "1",
"msg": "request success",
"data": {
"srcTransferObjName": "worker_stats",
"targetSchemaObjs": [
{
"dataJobId": 488,
"dataJobName": "canalmq0h45193p1",
"dataJobDesc": "1234",
"db": null,
"schema": null,
"transferObjName": "table_4"
},
{
"dataJobId": 469,
"dataJobName": "canal7200hxm2t8k",
"dataJobDesc": "1234",
"db": null,
"schema": "dingtax_from_src",
"transferObjName": "worker_stats"
},
{
"dataJobId": 468,
"dataJobName": "canal1c1zu6ye2dz",
"dataJobDesc": "1234",
"db": null,
"schema": "dingtax_from_mongo",
"transferObjName": "worker_stats_re"
},
{
"dataJobId": 463,
"dataJobName": "canal18s6ks5793k",
"dataJobDesc": "4123",
"db": null,
"schema": "dingtax_in_adb",
"transferObjName": "worker_stats"
},
{
"dataJobId": 462,
"dataJobName": "canal27h614pi7p7",
"dataJobDesc": "1234",
"db": "dingtax",
"schema": "dbo",
"transferObjName": "worker_stats"
},
{
"dataJobId": 458,
"dataJobName": "canall61uha92i1u",
"dataJobDesc": "1234",
"db": "dingtax",
"schema": "public",
"transferObjName": "worker_stats"
},
{
"dataJobId": 457,
"dataJobName": "canalqhuc714f31q",
"dataJobDesc": "1234",
"db": "dingtax",
"schema": "public",
"transferObjName": "worker_stats"
},
{
"dataJobId": 455,
"dataJobName": "canalz1yt0nutvr3",
"dataJobDesc": "1234",
"db": "dingtax",
"schema": "public",
"transferObjName": "worker_stats"
},
{
"dataJobId": 459,
"dataJobName": "canalc51a374175o",
"dataJobDesc": "123",
"db": "dingtax",
"schema": "public",
"transferObjName": "worker_stats"
}
]
},
"success": true,
"fail": false,
"rsocketDirectionType": null
}