Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewInstanceTreeBuilder ¶ added in v0.7.0
func NewInstanceTreeBuilder(db Backend) *instanceTreeBuilder
func NewServeMux ¶
NewServeMux returns an *http.ServeMux that serves the diagnostics web app at / and the diagnostics API at /api which is used by the web app.
Types ¶
type Backend ¶
type Backend interface { backend.Backend GetWorkflowInstance(ctx context.Context, instanceID string) (*WorkflowInstanceRef, error) GetWorkflowInstances(ctx context.Context, afterInstanceID string, count int) ([]*WorkflowInstanceRef, error) GetWorkflowTree(ctx context.Context, instanceID string) (*WorkflowInstanceTree, error) }
type Event ¶
type Event struct { ID string `json:"id,omitempty"` SequenceID int64 `json:"sequence_id,omitempty"` Type string `json:"type,omitempty"` Timestamp time.Time `json:"timestamp,omitempty"` ScheduleEventID int64 `json:"schedule_event_id,omitempty"` Attributes interface{} `json:"attributes,omitempty"` VisibleAt *time.Time `json:"visible_at,omitempty"` }
type WorkflowInstanceInfo ¶
type WorkflowInstanceInfo struct { *WorkflowInstanceRef History []*Event `json:"history,omitempty"` }
type WorkflowInstanceRef ¶
type WorkflowInstanceRef struct { Instance *core.WorkflowInstance `json:"instance,omitempty"` CreatedAt time.Time `json:"created_at,omitempty"` CompletedAt *time.Time `json:"completed_at,omitempty"` State core.WorkflowInstanceState `json:"state"` }
type WorkflowInstanceTree ¶ added in v0.7.0
type WorkflowInstanceTree struct { *WorkflowInstanceRef WorkflowName string `json:"workflow_name,omitempty"` Children []*WorkflowInstanceTree `json:"children,omitempty"` }
Click to show internal directories.
Click to hide internal directories.