Documentation
¶
Index ¶
- type NodeExecution
- func (n *NodeExecution) Delete(ctx context.Context, db bun.IDB) error
- func (n NodeExecution) GetCursor() string
- func (n NodeExecution) GetSortField() string
- func (n NodeExecution) GetSortValue() interface{}
- func (n NodeExecution) GetUniqueField() string
- func (n NodeExecution) GetUniqueValue() interface{}
- func (n *NodeExecution) Insert(ctx context.Context, db bun.IDB) error
- func (n *NodeExecution) Update(ctx context.Context, db bun.IDB) error
- func (n *NodeExecution) Validate() error
- type NodeExecutionStatus
- type WorkflowExecution
- func (w *WorkflowExecution) Delete(ctx context.Context, db bun.IDB) error
- func (w WorkflowExecution) GetCursor() string
- func (w WorkflowExecution) GetSortField() string
- func (w WorkflowExecution) GetSortValue() interface{}
- func (w WorkflowExecution) GetUniqueField() string
- func (w WorkflowExecution) GetUniqueValue() interface{}
- func (w *WorkflowExecution) Insert(ctx context.Context, db bun.IDB) error
- func (w *WorkflowExecution) Update(ctx context.Context, db bun.IDB) error
- func (w *WorkflowExecution) Validate() error
- type WorkflowExecutionStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NodeExecution ¶
type NodeExecution struct {
bun.BaseModel `bun:"table:node_executions"`
ID uuid.UUID `bun:",pk,type:uuid" json:"id"`
WorkflowExecutionID uuid.UUID `bun:"type:uuid" json:"workflow_execution_id"`
ParentNodeExecutionID uuid.UUID `bun:"type:uuid,nullzero" json:"parent_node_execution_id,omitempty"`
NodeID string `json:"node_id"`
Kind string `json:"kind"`
Status NodeExecutionStatus `json:"status"`
NodeSnapshot json.RawMessage `bun:"type:jsonb" json:"node_snapshot"`
InputSnapshot map[string]any `bun:"type:jsonb,nullzero" json:"input_snapshot,omitempty"`
OutputSnapshot map[string]any `bun:"type:jsonb,nullzero" json:"output_snapshot,omitempty"`
Trace map[string]any `bun:"type:jsonb,nullzero" json:"trace,omitempty"`
IterationIndex *int `bun:",nullzero" json:"iteration_index,omitempty"`
BranchName string `json:"branch_name,omitempty"`
StartedAt *time.Time `bun:",nullzero" json:"started_at,omitempty"`
FinishedAt *time.Time `bun:",nullzero" json:"finished_at,omitempty"`
Metadata map[string]any `bun:"type:jsonb,nullzero" json:"metadata,omitempty"`
CreatedAt time.Time `json:"created_at"`
}
func GetNodeExecutionByID ¶
func (NodeExecution) GetCursor ¶
func (n NodeExecution) GetCursor() string
func (NodeExecution) GetSortField ¶
func (n NodeExecution) GetSortField() string
func (NodeExecution) GetSortValue ¶
func (n NodeExecution) GetSortValue() interface{}
func (NodeExecution) GetUniqueField ¶
func (n NodeExecution) GetUniqueField() string
func (NodeExecution) GetUniqueValue ¶
func (n NodeExecution) GetUniqueValue() interface{}
func (*NodeExecution) Validate ¶
func (n *NodeExecution) Validate() error
type NodeExecutionStatus ¶
type NodeExecutionStatus string
const ( NodeExecutionStatusQueued NodeExecutionStatus = "queued" NodeExecutionStatusRunning NodeExecutionStatus = "running" NodeExecutionStatusSucceeded NodeExecutionStatus = "succeeded" NodeExecutionStatusFailed NodeExecutionStatus = "failed" NodeExecutionStatusCanceled NodeExecutionStatus = "canceled" NodeExecutionStatusBlocked NodeExecutionStatus = "blocked" )
func (NodeExecutionStatus) MarshalJSON ¶
func (s NodeExecutionStatus) MarshalJSON() ([]byte, error)
func (*NodeExecutionStatus) UnmarshalJSON ¶
func (s *NodeExecutionStatus) UnmarshalJSON(b []byte) error
func (NodeExecutionStatus) Validate ¶
func (s NodeExecutionStatus) Validate() error
type WorkflowExecution ¶
type WorkflowExecution struct {
bun.BaseModel `bun:"table:workflow_executions"`
ID uuid.UUID `bun:",pk,type:uuid" json:"id"`
WorkflowSlug string `json:"workflow_slug"`
// WorkflowID is the workflow's permanent identity — the slug can
// be renamed, this cannot.
WorkflowID uuid.UUID `bun:"type:uuid,nullzero" json:"workflow_id,omitempty"`
WorkflowVersion string `json:"workflow_version"`
WorkflowSnapshot json.RawMessage `bun:"type:jsonb" json:"workflow_snapshot"`
InputSnapshot map[string]any `bun:"type:jsonb,nullzero" json:"input_snapshot,omitempty"`
OutputSnapshot map[string]any `bun:"type:jsonb,nullzero" json:"output_snapshot,omitempty"`
Status WorkflowExecutionStatus `json:"status"`
ProjectDir string `json:"project_dir,omitempty"`
StartedAt *time.Time `bun:",nullzero" json:"started_at,omitempty"`
FinishedAt *time.Time `bun:",nullzero" json:"finished_at,omitempty"`
Metadata map[string]any `bun:"type:jsonb,nullzero" json:"metadata,omitempty"`
CreatedAt time.Time `json:"created_at"`
}
func (WorkflowExecution) GetCursor ¶
func (w WorkflowExecution) GetCursor() string
func (WorkflowExecution) GetSortField ¶
func (w WorkflowExecution) GetSortField() string
func (WorkflowExecution) GetSortValue ¶
func (w WorkflowExecution) GetSortValue() interface{}
func (WorkflowExecution) GetUniqueField ¶
func (w WorkflowExecution) GetUniqueField() string
func (WorkflowExecution) GetUniqueValue ¶
func (w WorkflowExecution) GetUniqueValue() interface{}
func (*WorkflowExecution) Validate ¶
func (w *WorkflowExecution) Validate() error
type WorkflowExecutionStatus ¶
type WorkflowExecutionStatus string
const ( WorkflowExecutionStatusQueued WorkflowExecutionStatus = "queued" WorkflowExecutionStatusRunning WorkflowExecutionStatus = "running" WorkflowExecutionStatusSucceeded WorkflowExecutionStatus = "succeeded" WorkflowExecutionStatusFailed WorkflowExecutionStatus = "failed" WorkflowExecutionStatusCanceled WorkflowExecutionStatus = "canceled" WorkflowExecutionStatusBlocked WorkflowExecutionStatus = "blocked" )
func (WorkflowExecutionStatus) MarshalJSON ¶
func (s WorkflowExecutionStatus) MarshalJSON() ([]byte, error)
func (*WorkflowExecutionStatus) UnmarshalJSON ¶
func (s *WorkflowExecutionStatus) UnmarshalJSON(b []byte) error
func (WorkflowExecutionStatus) Validate ¶
func (s WorkflowExecutionStatus) Validate() error
Click to show internal directories.
Click to hide internal directories.