导出工作流为JSON格式,包含工作流基本信息、工作流内所有节点信息、工作流的DAG依赖关系
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
调试
授权信息
请求参数
|
名称 |
类型 |
必填 |
描述 |
示例值 |
| ClusterId |
string |
是 |
A short description of struct |
xxljob-b6ec1xxxx |
| WorkflowId |
array |
否 |
工作流 ID。 |
|
|
integer |
否 |
工作流 ID |
20 |
|
| AppName |
string |
是 |
应用名称。 |
test-app |
返回参数
|
名称 |
类型 |
描述 |
示例值 |
|
string |
请求体。 |
[{"kind":"SchedulerXWorkflows","type":"JSON","version":"2.0","workflowInfo":{"name":"myWorkflow","description":"","appName":"xuerentest","appType":1,"maxConcurrency":1,"currentExecuteStatus":0,"timeConfig":{"timeType":1,"timeExpression":"0 0 12 * * ?","dataOffset":0}},"nodes":[{"name":"Java1","startTime":-1,"coordinate":{"x":-222.0,"y":40.0,"width":220.0,"height":76.0},"appName":"xuerentest","description":"","jobType":"xxljob","executeMode":"standalone","contentType":1,"content":"{\"jobHandler\":\"helloworld\"}","xattrs":"{\"executorBlockStrategy\":1}","dependentStrategy":1,"routeStrategy":1,"parameters":"","maxConcurrency":1,"maxAttempt":0,"attemptInterval":30,"priority":5,"weight":1,"timeConfig":{"timeType":1,"calendar":"","dataOffset":0},"monitorConfigInfo":{"timeoutEnable":true,"failEnable":true,"failLimitTimes":1,"failRate":100,"missWorkerEnable":true,"timeout":300,"timeoutKillEnable":false,"daysOfDeadline":0,"sendChannel":"","alarmType":"CustomContacts","successNotice":false,"endEarlyEnable":false,"endEarly":30},"contactInfoList":[]},{"name":"shell1","startTime":-1,"coordinate":{"x":102.0,"y":-51.0,"width":220.0,"height":76.0},"appName":"xuerentest","description":"","jobType":"script_shell","executeMode":"standalone","contentType":2,"content":"echo \"hello world\"","xattrs":"{\"executorBlockStrategy\":1}","dependentStrategy":1,"routeStrategy":1,"parameters":"","maxConcurrency":1,"maxAttempt":0,"attemptInterval":30,"priority":5,"weight":1,"timeConfig":{"timeType":1,"calendar":"","dataOffset":0},"monitorConfigInfo":{"timeoutEnable":true,"failEnable":true,"failLimitTimes":1,"failRate":100,"missWorkerEnable":true,"timeout":300,"timeoutKillEnable":false,"daysOfDeadline":0,"sendChannel":"","alarmType":"CustomContacts","successNotice":false,"endEarlyEnable":false,"endEarly":30},"contactInfoList":[]},{"name":"Java2","startTime":-1,"coordinate":{"x":390.0,"y":55.0,"width":220.0,"height":76.0},"appName":"xuerentest","description":"","jobType":"xxljob","executeMode":"standalone","contentType":1,"content":"{\"jobHandler\":\"helloworld2\"}","xattrs":"{\"executorBlockStrategy\":1,\"localParams\":[]}","dependentStrategy":1,"routeStrategy":1,"parameters":"","maxConcurrency":1,"maxAttempt":0,"attemptInterval":30,"priority":5,"weight":1,"timeConfig":{"timeType":1,"calendar":"","dataOffset":0},"monitorConfigInfo":{"timeoutEnable":true,"failEnable":true,"failLimitTimes":1,"failRate":100,"missWorkerEnable":true,"timeout":300,"timeoutKillEnable":false,"daysOfDeadline":0,"sendChannel":"","alarmType":"CustomContacts","successNotice":false,"endEarlyEnable":false,"endEarly":30},"contactInfoList":[]},{"name":"shell2","startTime":-1,"coordinate":{"x":89.0,"y":161.0,"width":220.0,"height":76.0},"appName":"xuerentest","description":"","jobType":"script_shell","executeMode":"standalone","contentType":2,"content":"echo \"hello world2\"","xattrs":"{\"executorBlockStrategy\":1}","dependentStrategy":1,"routeStrategy":1,"parameters":"","maxConcurrency":1,"maxAttempt":0,"attemptInterval":30,"priority":5,"weight":1,"timeConfig":{"timeType":1,"calendar":"","dataOffset":0},"monitorConfigInfo":{"timeoutEnable":true,"failEnable":true,"failLimitTimes":1,"failRate":100,"missWorkerEnable":true,"timeout":300,"timeoutKillEnable":false,"daysOfDeadline":0,"sendChannel":"","alarmType":"CustomContacts","successNotice":false,"endEarlyEnable":false,"endEarly":30},"contactInfoList":[]}],"edges":[{"from":"Java1","to":"shell1"},{"from":"Java1","to":"shell2"},{"from":"Schedulerx-Root","to":"Java1"},{"from":"shell1","to":"Java2"},{"from":"shell2","to":"Java2"}]}] |
示例
正常返回示例
JSON格式
"[{\"kind\":\"SchedulerXWorkflows\",\"type\":\"JSON\",\"version\":\"2.0\",\"workflowInfo\":{\"name\":\"myWorkflow\",\"description\":\"\",\"appName\":\"xuerentest\",\"appType\":1,\"maxConcurrency\":1,\"currentExecuteStatus\":0,\"timeConfig\":{\"timeType\":1,\"timeExpression\":\"0 0 12 * * ?\",\"dataOffset\":0}},\"nodes\":[{\"name\":\"Java1\",\"startTime\":-1,\"coordinate\":{\"x\":-222.0,\"y\":40.0,\"width\":220.0,\"height\":76.0},\"appName\":\"xuerentest\",\"description\":\"\",\"jobType\":\"xxljob\",\"executeMode\":\"standalone\",\"contentType\":1,\"content\":\"{\\\"jobHandler\\\":\\\"helloworld\\\"}\",\"xattrs\":\"{\\\"executorBlockStrategy\\\":1}\",\"dependentStrategy\":1,\"routeStrategy\":1,\"parameters\":\"\",\"maxConcurrency\":1,\"maxAttempt\":0,\"attemptInterval\":30,\"priority\":5,\"weight\":1,\"timeConfig\":{\"timeType\":1,\"calendar\":\"\",\"dataOffset\":0},\"monitorConfigInfo\":{\"timeoutEnable\":true,\"failEnable\":true,\"failLimitTimes\":1,\"failRate\":100,\"missWorkerEnable\":true,\"timeout\":300,\"timeoutKillEnable\":false,\"daysOfDeadline\":0,\"sendChannel\":\"\",\"alarmType\":\"CustomContacts\",\"successNotice\":false,\"endEarlyEnable\":false,\"endEarly\":30},\"contactInfoList\":[]},{\"name\":\"shell1\",\"startTime\":-1,\"coordinate\":{\"x\":102.0,\"y\":-51.0,\"width\":220.0,\"height\":76.0},\"appName\":\"xuerentest\",\"description\":\"\",\"jobType\":\"script_shell\",\"executeMode\":\"standalone\",\"contentType\":2,\"content\":\"echo \\\"hello world\\\"\",\"xattrs\":\"{\\\"executorBlockStrategy\\\":1}\",\"dependentStrategy\":1,\"routeStrategy\":1,\"parameters\":\"\",\"maxConcurrency\":1,\"maxAttempt\":0,\"attemptInterval\":30,\"priority\":5,\"weight\":1,\"timeConfig\":{\"timeType\":1,\"calendar\":\"\",\"dataOffset\":0},\"monitorConfigInfo\":{\"timeoutEnable\":true,\"failEnable\":true,\"failLimitTimes\":1,\"failRate\":100,\"missWorkerEnable\":true,\"timeout\":300,\"timeoutKillEnable\":false,\"daysOfDeadline\":0,\"sendChannel\":\"\",\"alarmType\":\"CustomContacts\",\"successNotice\":false,\"endEarlyEnable\":false,\"endEarly\":30},\"contactInfoList\":[]},{\"name\":\"Java2\",\"startTime\":-1,\"coordinate\":{\"x\":390.0,\"y\":55.0,\"width\":220.0,\"height\":76.0},\"appName\":\"xuerentest\",\"description\":\"\",\"jobType\":\"xxljob\",\"executeMode\":\"standalone\",\"contentType\":1,\"content\":\"{\\\"jobHandler\\\":\\\"helloworld2\\\"}\",\"xattrs\":\"{\\\"executorBlockStrategy\\\":1,\\\"localParams\\\":[]}\",\"dependentStrategy\":1,\"routeStrategy\":1,\"parameters\":\"\",\"maxConcurrency\":1,\"maxAttempt\":0,\"attemptInterval\":30,\"priority\":5,\"weight\":1,\"timeConfig\":{\"timeType\":1,\"calendar\":\"\",\"dataOffset\":0},\"monitorConfigInfo\":{\"timeoutEnable\":true,\"failEnable\":true,\"failLimitTimes\":1,\"failRate\":100,\"missWorkerEnable\":true,\"timeout\":300,\"timeoutKillEnable\":false,\"daysOfDeadline\":0,\"sendChannel\":\"\",\"alarmType\":\"CustomContacts\",\"successNotice\":false,\"endEarlyEnable\":false,\"endEarly\":30},\"contactInfoList\":[]},{\"name\":\"shell2\",\"startTime\":-1,\"coordinate\":{\"x\":89.0,\"y\":161.0,\"width\":220.0,\"height\":76.0},\"appName\":\"xuerentest\",\"description\":\"\",\"jobType\":\"script_shell\",\"executeMode\":\"standalone\",\"contentType\":2,\"content\":\"echo \\\"hello world2\\\"\",\"xattrs\":\"{\\\"executorBlockStrategy\\\":1}\",\"dependentStrategy\":1,\"routeStrategy\":1,\"parameters\":\"\",\"maxConcurrency\":1,\"maxAttempt\":0,\"attemptInterval\":30,\"priority\":5,\"weight\":1,\"timeConfig\":{\"timeType\":1,\"calendar\":\"\",\"dataOffset\":0},\"monitorConfigInfo\":{\"timeoutEnable\":true,\"failEnable\":true,\"failLimitTimes\":1,\"failRate\":100,\"missWorkerEnable\":true,\"timeout\":300,\"timeoutKillEnable\":false,\"daysOfDeadline\":0,\"sendChannel\":\"\",\"alarmType\":\"CustomContacts\",\"successNotice\":false,\"endEarlyEnable\":false,\"endEarly\":30},\"contactInfoList\":[]}],\"edges\":[{\"from\":\"Java1\",\"to\":\"shell1\"},{\"from\":\"Java1\",\"to\":\"shell2\"},{\"from\":\"Schedulerx-Root\",\"to\":\"Java1\"},{\"from\":\"shell1\",\"to\":\"Java2\"},{\"from\":\"shell2\",\"to\":\"Java2\"}]}]"
错误码
|
HTTP status code |
错误码 |
错误信息 |
描述 |
|---|---|---|---|
| 400 | InvalidParameter | Parameter error: %s. | 参数错误: %s |
| 401 | IllegalRequest | IllegalRequest: %s. | 非法请求:%s |
| 500 | InternalError | InternalError: %s. | 系统内部错误:%s |
| 403 | NoPermission | No permission to perform this operation: %s. | 没有权限去执行该操作:%s |
| 404 | NotFound | Not found: %s. | 资源不存在:%s |
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。