Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RaiseEventRequest ¶
type RaiseEventRequest struct { InstanceID string `json:"workflow_reference"` EventName string `json:"event_name"` Input []byte `json:"input"` }
RaiseEventRequest is the object describing a Raise Event request.
type StartRequest ¶
type StartRequest struct { Options map[string]string `json:"workflow_options"` InstanceID string `json:"workflow_reference"` WorkflowName string `json:"function_name"` Input interface{} `json:"input"` }
StartRequest is the object describing a Start Workflow request.
type StateResponse ¶
type StateResponse struct { WFInfo WorkflowReference StartTime string `json:"start_time"` Metadata map[string]string `json:"metadata"` }
type Workflow ¶
type Workflow interface { Init(metadata Metadata) error Start(ctx context.Context, req *StartRequest) (*WorkflowReference, error) Terminate(ctx context.Context, req *WorkflowReference) error Get(ctx context.Context, req *WorkflowReference) (*StateResponse, error) RaiseEvent(ctx context.Context, req *RaiseEventRequest) error Pause(ctx context.Context, req *WorkflowReference) error Resume(ctx context.Context, req *WorkflowReference) error GetComponentMetadata() map[string]string }
Workflow is an interface to perform operations on Workflow.
type WorkflowReference ¶
type WorkflowReference struct {
InstanceID string `json:"instance_id"`
}
Click to show internal directories.
Click to hide internal directories.