文档

CreatePipelineRun - 创建工作流任务

更新时间:

创建工作流任务。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

调试

授权信息

当前API暂无授权信息透出。

请求语法

POST /api/v1/pipelineruns

请求参数

名称类型必填描述示例值
bodyobject

工作流任务。

PipelineIdstring

工作流的ID。 PipelineId和PipelineManifest二选一。

flow-rer7y***
Namestring

工作流任务名字。若为空,则自动生成名字。

testName
PipelineManifeststring

工作流定义,具体样例见下方请求参数补充说明。 PipelineId和PipelineManifest二选一。

apiVersion: "core/v1"*********
Argumentsstring

参数。

arguments: parameters: - name: "execution_maxcompute" value: endpoint: "http://service***" odpsProject: "pai***"
NoConfirmRequiredboolean

是否直接启动pipelineRun,取值如下:

  • true代表直接启动(默认)。
  • false代表只创建run,但先不启动。
true
WorkspaceIdstring

工作空间ID。

84***
SourceTypestring

工作流任务来源类型,支持如下值:

  • UNKNOWN(默认)
  • SDK
  • DESIGNER
  • M6
UNKNOWN
SourceIdstring

来源ID。

experiment-ybpy***
Optionsstring

创建工作流任务选项,格式为JSON。

{"mlflow":{"experimentId":"exp-1jdk***"}}
Accessibilitystring

工作空间可见性:

  • PUBLIC(默认)
  • PRIVATE
PUBLIC

工作流定义样例:该工作流由读数据表(data_source),类型转换(type_transform)组成。

apiVersion: "core/v1"
metadata:
  provider: "1557702098******"
  version: "v1"
  identifier: "my_pipeline"
  name: "source-transform"
spec:
  inputs:
    parameters:
    - name: "execution_maxcompute"
      type: "Map"
  pipelines:
  - apiVersion: "core/v1"
    metadata:
      provider: "pai"
      version: "v1"
      identifier: "data_source"
      name: "data_source"
      displayName: "读数据表-1"
    spec:
      arguments:
        parameters:
        - name: "inputTableName"
          value: "pai_online_project.wumai_data"
        - name: "partition"
          value: "20220101"
        - name: "execution"
          from: "{{inputs.parameters.execution_maxcompute}}"
  - apiVersion: "core/v1"
    metadata:
      provider: "pai"
      version: "v1"
      identifier: "type_transform"
      name: "type_transform"
      displayName: "类型转换-1"
    spec:
      arguments:
        artifacts:
        - name: "inputTable"
          from: "{{pipelines.data_source.outputs.artifacts.outputTable}}"
        parameters:
        - name: "cols_to_double"
          value: "time,hour,pm2,pm10,so2,co,no2"
        - name: "execution"
          from: "{{inputs.parameters.execution_maxcompute}}"
      dependencies:
      - "data_source"

返回参数

名称类型描述示例值
object

返回结构体。

RequestIdstring

请求ID。

DA869D1B-035A-43B2-ACC1-C56681BD9FAA
PipelineRunIdstring

工作流任务ID。

flow-rbvg***

示例

正常返回示例

JSON格式

{
  "RequestId": "DA869D1B-035A-43B2-ACC1-C56681BD9FAA",
  "PipelineRunId": "flow-rbvg***"
}

错误码

访问错误中心查看更多错误码。

变更历史

变更时间变更内容概要操作
2022-06-16API 内部配置变更,不影响调用看变更集
变更项变更内容
API 内部配置变更,不影响调用
2022-06-14新增 OpenAPI看变更集
  • 本页导读 (1)
文档反馈