processor

package
v0.0.0-...-19e0465 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 12, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TerminateProcess

func TerminateProcess(ctx context.Context, input *terminateProcessInput) (*terminateProcessOutput, error)

TerminateProcess 终止流程 强制终止流程实例,如果当前流程实例状态是已完成,引擎什么也不做,否则引擎会将状态置为已终止 注意,一旦流程已完成或者已终止,引擎将不再允许提交和回滚

Types

type CommitTaskInput

type CommitTaskInput struct {
	FlowInstanceID string                 `json:"flow_instance_id" v:"required"`
	TaskInstanceID string                 `json:"task_instance_id" v:"required"`
	Variables      map[string]interface{} `json:"variables"`
}

type CommitTaskOutput

type CommitTaskOutput struct {
	FlowInstanceID     string                 `json:"flow_instance_id"`
	FlowInstanceStatus int8                   `json:"flow_instance_status"`
	ActiveTaskInstance *ent.FlowNodeInstance  `json:"active_task_instance"`
	Variables          map[string]interface{} `json:"variables"`
}

func CommitTask

func CommitTask(ctx context.Context, input *CommitTaskInput) (*CommitTaskOutput, error)

CommitTask 提交任务 引擎从指定的用户任务节点开始执行,直到用户任务节点挂起或者结束节点完成

type RollbackTaskInput

type RollbackTaskInput struct {
	FlowInstanceID string
	TaskInstanceID string
}

type RollbackTaskOutput

type RollbackTaskOutput struct {
	FlowInstanceID     string                 `json:"flow_instance_id"`
	FlowInstanceStatus int8                   `json:"flow_instance_status"`
	ActiveTaskInstance *ent.FlowNodeInstance  `json:"active_task_instance"`
	Variables          map[string]interface{} `json:"variables"`
}

func RollbackTask

func RollbackTask(ctx context.Context, input *RollbackTaskInput) (*RollbackTaskOutput, error)

RollbackTask 回滚任务 引擎从指定的用户任务节点开始回滚,直到用户任务节点挂起或者开始节点结束

type StartProcessInput

type StartProcessInput struct {
	RefID            string                 `json:"ref_id" v:"required"`
	FlowDeploymentID string                 `json:"flow_deployment_id" v:"required"`
	Variables        map[string]interface{} `json:"variables"`
}

type StartProcessOutput

type StartProcessOutput struct {
	ProcessStatus      int8                   `json:"process_status"`
	FlowDeploymentID   string                 `json:"flow_deployment_id"`
	FlowInstanceID     string                 `json:"flow_instance_id"`
	FlowInstanceStatus int8                   `json:"flow_instance_status"`
	ActiveNodeInstance *ent.FlowNodeInstance  `json:"active_node_instance"`
	Variables          map[string]interface{} `json:"variables"`
}

func StartProcess

func StartProcess(ctx context.Context, input *StartProcessInput) (*StartProcessOutput, error)

StartProcess 流程执行 创建流程实例,从开始节点开始执行,直到用户任务节点挂起或者结束节点完成。

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL