workflow

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: May 14, 2019 License: GPL-3.0 Imports: 17 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package workflow defines the Role interface, along with tooling to build the control tree. A workflow is a tree of Roles, and it's loaded from Configuration with a combination of YAML unmarshaling and Go template execution.

Index

Constants

View Source
const (
	PATH_SEPARATOR      = "."
	PATH_SEPARATOR_RUNE = '.'
)
View Source
const (
	ConfigBasePath = "o2/control/workflows"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type GetEnvIdFunc

type GetEnvIdFunc func() uuid.Array

type ParentAdapter

type ParentAdapter struct {
	// contains filtered or unexported fields
}

func NewParentAdapter

func NewParentAdapter(getEnvId GetEnvIdFunc) *ParentAdapter

func (*ParentAdapter) CollectOutboundChannels

func (*ParentAdapter) CollectOutboundChannels() []channel.Outbound

func (*ParentAdapter) GetEnvironmentId

func (p *ParentAdapter) GetEnvironmentId() uuid.Array

func (*ParentAdapter) GetParent

func (i *ParentAdapter) GetParent() Updatable

func (*ParentAdapter) GetPath

func (*ParentAdapter) GetPath() string

func (*ParentAdapter) SubscribeToStateChange

func (p *ParentAdapter) SubscribeToStateChange(subscriptionId string, c chan task.State)

func (*ParentAdapter) SubscribeToStatusChange

func (p *ParentAdapter) SubscribeToStatusChange(subscriptionId string, c chan task.Status)

func (*ParentAdapter) UnsubscribeFromStateChange

func (p *ParentAdapter) UnsubscribeFromStateChange(subscriptionId string)

func (*ParentAdapter) UnsubscribeFromStatusChange

func (p *ParentAdapter) UnsubscribeFromStatusChange(subscriptionId string)

type Role

type Role interface {
	GetParent() Updatable
	GetParentRole() Role
	GetRoles() []Role
	GetPath() string
	GetName() string
	GetStatus() task.Status
	GetState() task.State
	GetTasks() []*task.Task
	GenerateTaskDescriptors() task.Descriptors

	ProcessTemplates() error
	GlobFilter(g glob.Glob) []Role
	// contains filtered or unexported methods
}

func Load

func Load(cfg configuration.ROSource, workflowPath string, parent Updatable) (workflow Role, err error)

FIXME: workflowPath should be of type configuration.Path, not string

type SafeState

type SafeState struct {
	// contains filtered or unexported fields
}

type SafeStatus

type SafeStatus struct {
	// contains filtered or unexported fields
}

type Updatable

type Updatable interface {
	GetParent() Updatable

	GetEnvironmentId() uuid.Array
	GetPath() string
	CollectOutboundChannels() []channel.Outbound
	// contains filtered or unexported methods
}

Jump to

Keyboard shortcuts

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