调用DescribeFlow接口,查询工作流信息。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
请求参数
名称 | 类型 | 是否必选 | 示例值 | 描述 |
---|---|---|---|---|
Action | String | 是 | DescribeFlow |
系统规定参数。对于您自行拼凑HTTP或HTTPS URL发起的API请求,该参数为必选参数。取值:DescribeFlow。 |
Id | String | 是 | F-7A39731FE719**** |
工作流ID。您可以调用ListFlowInstance查看工作流ID。 |
ProjectId | String | 是 | FP-257A173659F5**** |
项目ID。您可以调用ListFlowProject查看项目的ID。 |
RegionId | String | 是 | cn-hangzhou |
地域ID。您可以调用DescribeRegions查看最新的阿里云地域列表。 |
返回数据
名称 | 类型 | 示例值 | 描述 |
---|---|---|---|
AlertConf | String | {"items":[{"enable":true,"eventId":"EMR-210401001","alertUserGroupIdList":["AUG-b79bb29bb6e14ddd89674a242623851b"],"alertDingDingGroupList":["ADG-af1f9689d6194e2dbd89927d5c515172"]},{"enable":true,"eventId":"EMR-110401015","alertUserGroupIdList":["AUG-b79bb29bb6e14ddd89674a242623851b"],"alertDingDingGroupList":["ADG-af1f9689d6194e2dbd89927d5c515172"]},{"enable":true,"eventId":"EMR-110401002","alertUserGroupIdList":["AUG-b79bb29bb6e14ddd89674a242623851b"],"alertDingDingGroupList":["ADG-af1f9689d6194e2dbd89927d5c515172"]}]} |
报警通知配置,eventId目前支持:
|
AlertDingDingGroupBizId | String | AUG-c917bbfaf6494bbfacdee69c8284967c |
报警钉钉群信息。 |
AlertUserGroupBizId | String | ADG-0a00d00abb7743ff9f812f1a997f3d87 |
报警用户组信息。 |
Application | String | {"nodeDefMap":{":start:":{"name":":start:","type":":start:","transitions":["cluster"]},"cluster":{"id":"CT-0C74281682CF03B4","name":"cluster","type":":Cluster:","transitions":["job1"]},"job1":{"jobId":"FJ-242AB240DBAF4195","name":"job1","type":":action:","transitions":["end"]},"end":{"name":"end","type":":end:"}}} |
工作流构造信息,由一组节点定义nodeDefMap组成,多个时以逗号分隔。
|
CategoryId | String | FC-F2495319DA05**** |
工作流目录ID。 |
ClusterId | String | C-A23BD131A862**** |
集群或集群模板ID。 |
CreateCluster | Boolean | false |
是否创建集群:
|
CronExpr | String | 0 0 0-23/1 * * ? |
调度Cron表达式。 |
Description | String | 这是一个创建工作流描述 |
工作流描述。 |
EditLockDetail | String | {} |
编辑锁信息。 |
EndSchedule | Long | 1538018814000 |
结束调度时间。 |
GmtCreate | Long | 1538017814000 |
创建时间。 |
GmtModified | Long | 1538017814000 |
修改时间。 |
Graph | String | {"nodes":[{"id":"48d474ea","index":0,"spmAnchorId":"0.0.0.i0.766645eb2cmNtQ","attribute":{"type":"START"},"shape":"startControlNode","type":"node","y":250,"size":"80*34","x":500},{"id":"7ba480b3","index":1,"spmAnchorId":"5176.8250060.0.i19.771e28d0IPNQGE","attribute":{"jobType":"SHELL","jobId":"FJ-7BE1062897B19D25","type":"JOB"},"config":{"hostName":""},"label":"fail_job","shape":"shellJobNode","type":"node","y":398.5,"size":"170*34","x":470.5},{"id":"33202d60","index":2,"spmAnchorId":"5176.8250060.0.i23.771e28d0IPNQGE","attribute":{"type":"END"},"shape":"endControlNode","type":"node","y":562.5,"size":"80*34","x":430.5}],"edges":[{"id":"28167ea0","index":3,"source":"48d474ea","sourceAnchor":0,"target":"7ba480b3","targetAnchor":0},{"id":"e8d5ff52","index":4,"source":"7ba480b3","sourceAnchor":1,"target":"33202d60","targetAnchor":0}]} |
图形信息。 |
HostName | String | emr-header-1.cluster-123456 |
指定运行的机器信息,格式为emr-header-1.cluster-123456。 |
Id | String | F-7A39731FE719**** |
工作流ID。 |
Lifecycle | String | 无 |
保留参数。 |
LogArchiveLocation | String | 无 |
保留参数。 |
Name | String | my_flow_demo |
工作流名称。 |
Namespace | String | 无 |
保留参数。 |
ParentFlowList | Array of ParentFlow |
依赖的父工作流列表。 |
|
ParentFlow | |||
ParentFlowId | String | F-123456 |
父工作流ID。 |
ParentFlowName | String | parent_flow |
父工作流名称。 |
ProjectId | String | FP-257A173659F5**** |
项目ID。 |
ProjectName | String | my_project |
项目名称。 |
Periodic | Boolean | true |
是否周期执行:
|
RequestId | String | 243D5A48-96A5-4C0C-8966-93CBF65635ED |
请求ID。 |
StartSchedule | Long | 1538017814000 |
开始调度时间。 |
Status | String | STOP_SCHEDULE |
支持状态:
|
Type | String | EMR |
目前只支持EMR。 |
示例
请求示例
http(s)://[Endpoint]/?Action=DescribeFlow
&Id=F-7A39731FE719****
&ProjectId=FP-257A173659F5****
&RegionId=cn-hangzhou
&<公共请求参数>
正常返回示例
XML
格式
<alertUserGroupBizId/>
<Description>flow</Description>
<Type>EMR</Type>
<CreateCluster>false</CreateCluster>
<GmtCreate>1533294723000</GmtCreate>
<GmtModified>1535449545000</GmtModified>
<HostName/>
<Name>flow</Name>
<Status>STOP_SCHEDULE</Status>
<ParentFlowList>
</ParentFlowList>
<CategoryId>FC-020BA6E39BF0****</CategoryId>
<alertDingDingGroupBizId/>
<ClusterId>C-23D6879E9BBE****</ClusterId>
<Periodic>false</Periodic>
<RequestId>E909BE04-1989-4751-93E6-1327FFC71EC0</RequestId>
<Graph>
<edges>
<id>af91****</id>
<index>2</index>
<sourceAnchor>0</sourceAnchor>
<source>48d474ea</source>
<target>f2764af5</target>
<targetAnchor>0</targetAnchor>
</edges>
<edges>
<id>3022****</id>
<index>4</index>
<source>48d474ea</source>
<sourceAnchor>0</sourceAnchor>
<target>ee4ee659</target>
<targetAnchor>0</targetAnchor>
</edges>
<edges>
<id>cfa9****</id>
<index>6</index>
<source>f2764af5</source>
<sourceAnchor>1</sourceAnchor>
<target>75ba7979</target>
<targetAnchor>0</targetAnchor>
</edges>
<edges>
<id>00cd****</id>
<index>7</index>
<source>ee4ee659</source>
<sourceAnchor>1</sourceAnchor>
<target>75ba7979</target>
<targetAnchor>0</targetAnchor>
</edges>
<edges>
<id>c53a****</id>
<index>9</index>
<source>75ba7979</source>
<sourceAnchor>1</sourceAnchor>
<target>ea5b3e8f</target>
<targetAnchor>0</targetAnchor>
</edges>
<nodes>
<id>f276****</id>
<index>0</index>
<spmAnchorId>5176.8250060.0.i158.771e28d0IP****</spmAnchorId>
<config>
<clusterId>C-E2544BF48603****</clusterId>
</config>
<attribute>
<jobType>SHELL</jobType>
<jobId>FJ-D9595F5B79AD****</jobId>
<type>JOB</type>
</attribute>
<label>echo</label>
<shape>shellJobNode</shape>
<type>node</type>
<y>394.5</y>
<x>321.25</x>
<size>170*34</size>
</nodes>
<nodes>
<id>48d4****</id>
<index>1</index>
<spmAnchorId>0.0.0.i0.766645eb2c****</spmAnchorId>
<attribute>
<type>START</type>
</attribute>
<shape>startControlNode</shape>
<type>node</type>
<y>262</y>
<size>80*34</size>
<x>500</x>
</nodes>
<nodes>
<id>ee4e****</id>
<index>3</index>
<spmAnchorId>5176.8250060.0.i11.6bb528d0eM****</spmAnchorId>
<attribute>
<jobType>SHELL</jobType>
<jobId>FJ-7BE1062897B1****</jobId>
<type>JOB</type>
</attribute>
<config>
<hostName/>
</config>
<label>fail_job</label>
<shape>shellJobNode</shape>
<type>node</type>
<y>456.5</y>
<size>170*34</size>
<x>518.125</x>
</nodes>
<nodes>
<id>75ba****</id>
<index>5</index>
<spmAnchorId>5176.8250060.0.i11.6bb528d0eM****</spmAnchorId>
<attribute>
<jobType>SHELL</jobType>
<jobId>FJ-D9595F5B79AD****</jobId>
<type>JOB</type>
</attribute>
<config>
<hostName>emr-header-1.cluster-71886</hostName>
<clusterId>C-7CE7BC10276E****</clusterId>
</config>
<label>echo</label>
<shape>shellJobNode</shape>
<type>node</type>
<y>585.5</y>
<size>170*34</size>
<x>250.125</x>
</nodes>
<nodes>
<id>ea5b****</id>
<index>8</index>
<spmAnchorId>5176.8250060.0.i19.6bb528d0eM****</spmAnchorId>
<attribute>
<type>END</type>
</attribute>
<shape>endControlNode</shape>
<type>node</type>
<y>700.5</y>
<size>80*34</size>
<x>239.125</x>
</nodes>
</Graph>
<Id>F-7A39731FE719****</Id>
JSON
格式
{
"alertUserGroupBizId": "",
"Description": "flow",
"Type": "EMR",
"CreateCluster": false,
"GmtCreate": 1533294723000,
"GmtModified": 1535449545000,
"HostName": "",
"Name": "flow",
"Status": "STOP_SCHEDULE",
"ParentFlowList": {
"ParentFlow": []
},
"CategoryId": "FC-020BA6E39BF0****",
"alertDingDingGroupBizId": "",
"ClusterId": "C-23D6879E9BBE****",
"Periodic": false,
"RequestId": "E909BE04-1989-4751-93E6-1327FFC71EC0",
"Graph": {
"edges": [
{
"id": "af91****",
"index": 2,
"sourceAnchor": 0,
"source": "48d474ea",
"target": "f2764af5",
"targetAnchor": 0
},
{
"id": "3022****",
"index": 4,
"source": "48d474ea",
"sourceAnchor": 0,
"target": "ee4ee659",
"targetAnchor": 0
},
{
"id": "cfa9****",
"index": 6,
"source": "f2764af5",
"sourceAnchor": 1,
"target": "75ba7979",
"targetAnchor": 0
},
{
"id": "00cd****",
"index": 7,
"source": "ee4ee659",
"sourceAnchor": 1,
"target": "75ba7979",
"targetAnchor": 0
},
{
"id": "c53a****",
"index": 9,
"source": "75ba7979",
"sourceAnchor": 1,
"target": "ea5b3e8f",
"targetAnchor": 0
}
],
"nodes": [
{
"id": "f276****",
"index": 0,
"spmAnchorId": "5176.8250060.0.i158.771e28d0IP****",
"config": {
"clusterId": "C-E2544BF48603****"
},
"attribute": {
"jobType": "SHELL",
"jobId": "FJ-D9595F5B79AD****",
"type": "JOB"
},
"label": "echo",
"shape": "shellJobNode",
"type": "node",
"y": 394.5,
"x": 321.25,
"size": "170*34"
},
{
"id": "48d4****",
"index": 1,
"spmAnchorId": "0.0.0.i0.766645eb2c****",
"attribute": {
"type": "START"
},
"shape": "startControlNode",
"type": "node",
"y": 262,
"size": "80*34",
"x": 500
},
{
"id": "ee4e****",
"index": 3,
"spmAnchorId": "5176.8250060.0.i11.6bb528d0eM****",
"attribute": {
"jobType": "SHELL",
"jobId": "FJ-7BE1062897B1****",
"type": "JOB"
},
"config": {
"hostName": ""
},
"label": "fail_job",
"shape": "shellJobNode",
"type": "node",
"y": 456.5,
"size": "170*34",
"x": 518.125
},
{
"id": "75ba****",
"index": 5,
"spmAnchorId": "5176.8250060.0.i11.6bb528d0eM****",
"attribute": {
"jobType": "SHELL",
"jobId": "FJ-D9595F5B79AD****",
"type": "JOB"
},
"config": {
"hostName": "emr-header-1.cluster-71886",
"clusterId": "C-7CE7BC10276E****"
},
"label": "echo",
"shape": "shellJobNode",
"type": "node",
"y": 585.5,
"size": "170*34",
"x": 250.125
},
{
"id": "ea5b****",
"index": 8,
"spmAnchorId": "5176.8250060.0.i19.6bb528d0eM****",
"attribute": {
"type": "END"
},
"shape": "endControlNode",
"type": "node",
"y": 700.5,
"size": "80*34",
"x": 239.125
}
]
},
"Id": "F-7A39731FE719****"
}