Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var RegularNodeStates = []NodeState{NodeStateCreated}
Functions ¶
This section is empty.
Types ¶
type DependencyManager ¶
type DependencyManager interface { // AddNode adds a node to the dependency manager. AddNode(name string) // AddDependency adds a dependency between depender and dependee. // The depender will effectively wait for the dependee to finish. AddDependency(dependee, depender string) error // WaitForNodeDependencies is called by a node that is meant to be created. // This call will bock until all the nodes that this node depends on are created. WaitForNodeDependencies(nodeName string) error // SignalDone is called by a node that has finished all tasks for the provided State. // internally the dependent nodes will be "notified" that an additional (if multiple exist) dependency is satisfied. SignalDone(nodeName string, state NodeState) // CheckAcyclicity checks if dependencies contain cycles. CheckAcyclicity() error // String returns a string representation of dependencies recorded with dependency manager. String() string // WaitForNodes blocks until all the nodes in the provided list have reached the provided state. WaitForNodes(nodeNames []string, status NodeState) error }
func NewDependencyManager ¶
func NewDependencyManager() DependencyManager
NewDependencyManager constructor.
Click to show internal directories.
Click to hide internal directories.